Skip to content

Optimize package size. Native Android plugins need to declare usage of v8 symbols explicitly in package.json now. #588

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

Merged
merged 3 commits into from
Oct 25, 2016

Conversation

petekanev
Copy link
Contributor

@petekanev petekanev commented Oct 17, 2016

Based on work previously done in #522 , this PR aims to build and distribute a reduced in size runtime package when a project dependency does not explicitly state that it consumes API exposed by the JavaScript engine (V8)

The optimizations come mostly from stripping the V8 symbol table, and account for about 3MB reduction in package size, combined, when all 3 supported android architectures are packed.

The optimized android runtime package will be used by default on android projects unless a dependency (nativescript plugin) has the useV8symbols: true key (subject to approval) inside their package.json's nativescript object, in which case the regular runtime distribution will be packed with the APK.

Depends on NativeScript/nativescript-cli#2138

Addresses #529

@NativeScript/android-runtime

@petekanev petekanev added this to the 2.4.0 milestone Oct 17, 2016
@ns-bot
Copy link

ns-bot commented Oct 17, 2016

💚

@ns-bot
Copy link

ns-bot commented Oct 25, 2016

💔

@petekanev
Copy link
Contributor Author

run CI

@ns-bot
Copy link

ns-bot commented Oct 25, 2016

💚

@petekanev petekanev merged commit 19ebca9 into master Oct 25, 2016
@petekanev petekanev changed the title Optimize package size Optimize package size. Native Android plugins need to declare usage of v8 symbols explicitly in package.json now. Oct 25, 2016
@petekanev petekanev deleted the optimize-size branch November 4, 2016 08:46
@slavchev slavchev added the done label Nov 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants