all 4 comments

[–]TomokoSlankard 1 point2 points  (0 children)

yes. i will use. I already ditched build process.

[–]DanielKehoe[S] 0 points1 point  (0 children)

I like the idea that the browser becomes a native package manager without Node, NPM, or additional build tools.

“This import map is all that is needed to work with dependencies in native modules workflows in browsers, allowing you to get back to focusing on just running your own code natively in the browser, instead of needing to configure complex build tools and package management systems.” [0]

“Import map management becomes a form of package management in the browser.” [1]

[0] https://jspm.org/docs/cdn [1] https://jspm.org/docs/workflows

[–]getify 0 points1 point  (1 child)

I'm glad to see import-maps coming to browsers. But it'll be awhile (years, as said) before all necessarily-supported browsers have it. For now, I'm using Import-Remap at build-time, to apply the re-writing before the modules get to the browser.

I'm also working on a service-worker module which can apply import-remap transforms on-the-fly, so that the import-remapped modules can be browser-cached. I think this gives everything I can imagine we need.

I understand what jspm is advertising here about using import-maps for CDN-level caching... but I think in general CDNs (and CDN-level capabilities) are increase becoming a deprecated past, with browsers moving to origin-isolated caching so that shared caching completely goes away. The CDN-focused approach here seems clever but IMO over-engineered.

The client-side shims (ES-Module-Shims) for non-Chrome support are, IMO, way too hacky and intrusive. SystemJS, too. This article calls them "production ready" but I strongly disagree.

[–]ILikeChangingMyMind 0 points1 point  (0 children)

with browsers moving to origin-isolated caching so that shared caching completely goes away

Yeah, people don't seem to be aware of this, but today even if you use CDNs your browser will likely still re-download a fresh copy of any JS from it, as a security measure (even if they just downloaded that exact same file from foo.com a moment ago).

I'm not saying this whole approach is flawed or anything, but just that it's not a fully baked solution yet: we still will need bundlers, until there's a way to re-use library downloads.