-
-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ES6 module build #224
Comments
How about |
same problem as with |
Those |
I'm asking because I'm not understanding: how does making a different package |
Well kinda, because if you dont use extras you do not have them. But it's not a good one. But another point. Why not include them all in the main bundle? All client bundlers (most likely either rollup or webpack) can do tree shaking with ES modules. The reason why we need a commonjs build is mainly for running the tests in node. But for the tests it does not matter if the bundle contains operators that are not used. And for the client bundle, extra operators (the ones that are not added to the |
I think you're right. If anyone is serious about reducing bundle size, they'll use tree shaking or something equivalent. xstream can still be committed to small size, though, by encouraging use of a few operators, simply because prototype operators are a bit more convenient than compose-able operators. We can do this breaking change together with the deprecation of time-based operators, currently in |
I will open a PR later |
Currently, |
Is is the issue resolved? I am still facing problems with rollup using xstream, can anyone please post a sample rollup config if they have figured it out... |
I'm currently profiling a cyclejs app and scope hoisting is not possible with xstream because of missing ES6 build.
The problem is again with the extra imports. The same problem we had with
@cycle/time
. So either:extra
operators (will cause problems with source maps for ES6 users)xstream
andxstream-extras
(this could also be splitted inxstream-time
) so if you are using@cycle/time
you do not bundle the time operators + we can deprecate it some day in the future)The text was updated successfully, but these errors were encountered: