4 ms·
Meanwhile, I found this on how Deno handles modules (it's all esm): https://www.sitepoint.com/deno-module-system-a-beginners-guide/ https://www.sitepoint.com/d
by e12e 6y ago
Meanwhile, I found this on how Deno handles modules (it's all esm):
https://www.sitepoint.com/deno-module-system-a-beginners-guide/ https://www.sitepoint.com/deno-module-system-a-beginners-gui...
Note that - if you can get an esm out of your cjs - and it doesn't use any nodejs apis unsupported by deno, then you might be able to use it:
> (...) Several CDNs can convert npm/CommonJS packages to ES2015 module URLs, including: Skypack.dev, jspm.org, unpkg.com (add a ?module querystring to a URL)
Ed: submitted as: https://news.ycombinator.com/item?id=24069037 https://news.ycombinator.com/item?id=24069037 since I couldn't find an earlier submission, and maybe it'll generate some interesting discussion on deno / modern js vs node.
In particular I wonder if it'll in practice be easier to share (more) code between backend and front-end.
- e12e 6y agoThere's also a crutch - I'm not sure how attractive it would be in a project using deno, though. Maybe to get up and running quickly on deno when moving a legacy project from nodejs? https://deno.land/std@0.63.0/node#commonjs-module-loading https://deno.land/std@0.63.0/node#commonjs-module-loading
- dane-pgp 6y ago> (it's all esm) Always has been.