Skip to content
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

Use default rollup polkadot.js config instead of webpack #28

Open
poka-IT opened this issue Jul 13, 2022 · 2 comments
Open

Use default rollup polkadot.js config instead of webpack #28

poka-IT opened this issue Jul 13, 2022 · 2 comments

Comments

@poka-IT
Copy link
Contributor

poka-IT commented Jul 13, 2022

Why do you use webpack instead of the default rollup conf existing for polkadot.js ?

https://github.com/polkadot-js/api/blob/master/rollup.config.mjs

Is there a technical reason ?

Rollup greatly minimizes the size of the build file since it selects only what is needed.
We thus go from 3.2MB currently generated by your webpack config to a few hundred KB

@poka-IT poka-IT changed the title Use default rollup polkadot.js config Use default rollup polkadot.js config instead of webpack Jul 13, 2022
@RomeroYang
Copy link
Member

cool, I will look into that.

@RomeroYang
Copy link
Member

The js_api in sdk need to be backward compatible with some lower version webview for android devices. I tried rollup but the output can not run on my device for it has some advanced syntax.

Maybe you can try to see if you can come up with a working rollup config for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants