DEV Community

loading...

Discussion on: A Simple Argument For Typescript

Collapse
patarapolw profile image
Pacharapol Withayasakpunt • Edited

I actually use // @ts-ignore more often than I should sometimes.

Especially when there is no @types/xxx and I don't want to create declaration.d.ts.

Explicit generic type declaration and as can also create faults.

But when I had to write JavaScript, I prefer to include types in JSDoc as well.

There is also things like false type security in TypeScript as well, especially when you would rather use @hapi/joi in JavaScript (or io-ts / runtypes in TypeScript, but TS will never force you to use it).

Forem Open with the Forem app