WebReflection / hyperHTML

A Fast & Light Virtual DOM Alternative
ISC License
3.07k stars 112 forks source link

HyperHtml Size #268

Closed Rincewind3d closed 6 years ago

Rincewind3d commented 6 years ago

The size of for libs used in WebComponents is very important. If they are small enough they can be bundled into the WebComponent to get a self contained element.

hyperHTML advertises on https://viperhtml.js.org/hyper.html that the size is less than 4k.

I can not confirm this. For me (all files are zipped) is min.js 5k esm.js 6k If I bundle it with webpack it’s 6k.

That doesn't sound like much. But if we use a lot of self containing WebComponents bundled with hyperHTML it matters.

Ideally hyperHTML should keep the promised less than 4k. Otherwise you should adjust your webpage. ;)

WebReflection commented 6 years ago

with brotli, the min is 4823 bytes and the size refers to that min one but you are right, the static text of the documentation needed an update, so that instead of a PR you came here complaining about 1K ... which is clearly the problem of modern Web: 1K.

This is also irrelevant for this library so I close this non-issue.

Regards

Rincewind3d commented 6 years ago

There's no need to be offended.

1k matters, because if a web component is self contained and bundles a lib hyperHTML this it will get a lot.

Let’s say you have 30 web components in your project, it make a difference if every web component has 3k oder 5k additional size.

So yes, 1k matters in this context ;)

WebReflection commented 6 years ago

I think the fact you distribute same library N times is the issue, not a single k in here.

But again, even 30 extra K are not the issue of the modern Web.

Regards.