-
Notifications
You must be signed in to change notification settings - Fork 240
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
rfc: @pika/pack available in stock npm #35
base: main
Are you sure you want to change the base?
Conversation
That would be a winner. Optimizing at this level could reduce time and resources from download to application build. Very cool proposal. |
This is related to an open idea on npm.community: https://npm.community/t/auto-publish-mini-version-for-npm-packages/274 Love the RFC! |
(Note: I build and maintain www.pikapkg.com & https://github.com/pikapkg/pack) +1, I'd obviously be thrilled to see npm integrate @pika/pack's approach to package building via simple config and a pipeline of composable build plugins & tools. A few thoughts from reading the RFC:
|
Just echoing some of my thoughts from the npm.community idea. I think there is value in publishing the build types under a separate scope that mirrors npm. For example, suppose we package redux as umd and cjs, then after building the two build types, publish just the build files along with a slimmed down package.json to What are your thoughts on this? |
I like the idea. Happy to discuss more in a different thread or offline (Edit: hope that doesn't come off as rude, just don't want to crowd out the convo here and make this thread about npm all about me) |
I’m a big fan of @pika/web. I’ve been wanting this bundler to exist for a long time now (even attempted to build it myself before I knew @pika/web was in the works). The biggest barrier that I ran into also seems to be affecting @pika/web: not enough npm modules ship ESM. When trying to use it, you see this error frequently:
With both Rollup (and @pika/pack), it’s now trivial to ship ESM alongside the usual CJS ( I’d advocate surfacing a warning on Once enough packages have ESM support, I believe @pika/web will be the new webpack, and will become the defacto way to ship client-side JS (and if not @pika/web itself, it’ll be an identical approach, because browsers now support ESM and this is the first bundler that takes full advantage of that). |
Until node has native ESM support, i don’t think that’s wise advice. Whatever node ships will be the only thing we’ll want the majority of the ecosystem also shipping, and anything different will be immediately obsolete. |
The original inquiry was from npm, so I have to assume the RFC and ensuing discussions is something they're interested in pursuing. I think the faster we can get to shipping a ready to dev using the browser the better. |
Here's a lil RFC suggesting that maybe @pika/pack should be directly integrated into npm.
rendered