Live data from Hacker News

Show HN: JohnnyDepp – A tiny dependency manager for modern browsers in 862 bytes

github.com

11–20 of 45 posts

Re: Show HN: JohnnyDepp – A tiny dependency manager for modern browsers in 862 bytes

#15
Please no. Write standard modules. Serve standard modules to modern browsers, optionally bundling to modules for production. Bundle to non-modules for legacy browsers.

Then we can all eventually move forward from this mess of non-standard module formats and loaders.

Re: Show HN: JohnnyDepp – A tiny dependency manager for modern browsers in 862 bytes

#16
post #14

I really don't understand modern web development. If people would build websites without shit, they wouldn't need stuff like this.

That's not for building simple static websites or simple blogs. That's for when you build a web application. Think Slack client, gmail, Jira, etc.

Re: Show HN: JohnnyDepp – A tiny dependency manager for modern browsers in 862 bytes

#18

Please no. Write standard modules. Serve standard modules to modern browsers, optionally bundling to modules for production. Bundle to non-modules for legacy browsers. Then we can all eventually move forward from this mess of non-standard module formats and loaders.

What are "standard modules" for modern browser? I don't typically frontend dev these days, so I'm likely a bit out of the loop.

The way I typically thought of dependencies with browsers was to bundle them all together. Is there some new solution to this problem?

Re: Show HN: JohnnyDepp – A tiny dependency manager for modern browsers in 862 bytes

#19

Please no. Write standard modules. Serve standard modules to modern browsers, optionally bundling to modules for production. Bundle to non-modules for legacy browsers. Then we can all eventually move forward from this mess of non-standard module formats and loaders.

What are "standard modules" for modern browser? I don't typically frontend dev these days, so I'm likely a bit out of the loop. The way I typically thought of dependencies with browsers was to bundle them all together. Is there some new solution to this problem?

They’re still mainly bundlers for now, such as webpack. But browsers are slowly adopting first class modules which has already been solidified by the spec afaik.

Re: Show HN: JohnnyDepp – A tiny dependency manager for modern browsers in 862 bytes

#20

Please no. Write standard modules. Serve standard modules to modern browsers, optionally bundling to modules for production. Bundle to non-modules for legacy browsers. Then we can all eventually move forward from this mess of non-standard module formats and loaders.

What are "standard modules" for modern browser? I don't typically frontend dev these days, so I'm likely a bit out of the loop. The way I typically thought of dependencies with browsers was to bundle them all together. Is there some new solution to this problem?

Probably using the ES2015 import syntax[1], which allows you to dynamically load modules. I have my doubts whether your average medium+ sized JS app will be that dynamically, so you'll probably end up slurping a whole lot o' module at startup. And without tree-shaking, more stuff to download and digest.

[1]https://caniuse.com/#feat=es6-module-dynamic-import

Post reply on HN