DEV Community

Discussion on: JS / TS?

Collapse
 
patarapolw profile image
Pacharapol Withayasakpunt • Edited

What is your goal? Knowing TypeScript might be helpful in maintaining some codebase, and of course TypeScript is popular, and a well structured way.

JavaScript might not be so bad, if you don't try to support most older browsers. The ways around this is not only TypeScript, but also Babel / Webpack. Perhaps also with JSDoc or Flow, to add typing.

TypeScript is not the only way to try to fix JavaScript as well. But I do agree that it is both approachable, and near-bare-bone JavaScript.

Perks of TypeScript? Actually, it is not always strongly-typed enough. But its typing system is both flexible and near-perfect to me.

Furthermore, you can easily use bare JavaScript without TypeScript or Babel in Node / Electron.