Code

Code

66 bookmarks
Custom sorting
JavaScript modules
JavaScript modules
All modern browsers support module features natively without needing transpilation. It can only be a good thing — browsers can optimize loading of modules, making it more efficient than having to use a library and do all of that extra client-side processing and extra round trips
The first thing you do to get access to module features is export them. This is done using the export statement
For example, the imports key in the import map below defines a "module specifier map" JSON object where the property names can be used as module specifiers, and the corresponding values will be substituted when the browser resolves the module URL.
Script files used by websites often have hashed filenames to simplify caching. The downside of this approach is that if a module changes, any modules that import it using its hashed filename will also need to be updated/regenerated.
·developer.mozilla.org·
JavaScript modules
camelAI
camelAI
·app.camelai.com·
camelAI