3 ms·
And it would be. The use case is when you need one function and want as small an import as possible.
by joelg 10y ago
And it would be. The use case is when you need one function and want as small an import as possible.
- fvargas 10y agoJavaScript has always been uniquely tied to the web, where page load times matter and serving a bunch of unnecessary data to a user can have a significantly negative impact. I think there is a balance to be struck with how we architect our libraries. In fact, ES6 module imports already go a long way in addressing these issues. Take a look at http://rollupjs.org http://rollupjs.org for how efficient module bundling can be done through the use of ES6