I want to use ref to create a class . It can be used as a class instance which can be called by .
in my ts file
export default declare class Cropper {
....
}
in my vue3 file
const cropper =ref<Cropper||undefined||null>()
I want to use ref to create a class . It can be used as a class instance which can be called by .
in my ts file
export default declare class Cropper {
....
}
in my vue3 file
const cropper =ref<Cropper||undefined||null>()
The syntax for
|
union types in TypeScript isn't the same as||
(logical OR) in JavaScript.It should be: