What does the “as” keyword do?

That is not vanilla JavaScript, it is TypeScript. As any means consider the typed object as a plain untyped JavaScrpt object.

The as keyword is a Type Assertion in TypeScript which tells the compiler to consider the object as another type than the type the compiler infers the object to be.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)