repsweet080303 / typescript-learning

0 stars 0 forks source link

Any #3

Open repsweet080303 opened 1 year ago

repsweet080303 commented 1 year ago

Any

TypeScript also has a special type any, that you can use whenever you don’t want a particular value to cause typechecking errors.

When a value is of type any, you can access any properties of it (which will in turn be of type any), call it like a function, assign it to (or from) a value of any type, or pretty much anything else that’s syntactically legal:

let myAny : any = 'any thing you want'