4

For a JavaScript beginner, Is it efficient to learn with or use "Strict Mode" while building stuff?

Comments
  • 5
    I don’t think it makes a huge difference. But please us ESLint, it grealt improves your learning process :)
  • 1
    Definitely use strict mode. It should be default but they cannot do that because of the need for support of older systems.
  • 2
    I'd even say start learning TypeScript and enable its --strict setting in the tsconfig.

    I'd come to hate the weak types of plain JavaScript and the compile time checks provide more sanity.
  • 2
    I would say it is efficient, but the question of using eslint or not is far more important.

    You'll save a lot of headaches using "use strict" but eslint will save you a lot more, and will warn you on lint time, before runtime.

    Also your code will be a lot better. I would still hate writing js if not for eslint, it's that important.
Add Comment