📢 PSA: Scripts are out, modules are in. If you are still using scripts, you're probably doing it wrong.

Modules are MUCH more than just syntax for import/export. They execute #JavaScript completely differently and BETTER than scripts—better scoping rules, instant strict mode, a neat dependency resolution algorithm… everything you can think of is better served by a module than by a script.

#webdev

@sir_pepe Great overview but shoud be "Not polluting global scope".
@sir_pepe where can I learn more about the "deterministic order" feature?

@sir_pepe

document.write() — an API so unholy its *absence* is indicated by a green check mark

@guenther it's THE worst, I love it.
@sir_pepe One thing I love is that along with top-level await, modules allow us to ship most of the newer JavaScript syntax without worrying about it breaking.