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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃彈 Remove bundlesize from package.json #20776

Merged
merged 1 commit into from Feb 11, 2019
Merged

馃彈 Remove bundlesize from package.json #20776

merged 1 commit into from Feb 11, 2019

Conversation

rsimha
Copy link
Contributor

@rsimha rsimha commented Feb 11, 2019

We use the bundlesize package to compute the size of the AMP runtime during PR checks. This is done here:

function getGzippedBundleSize() {
const cmd = `npx bundlesize -f "${runtimeFile}"`;
log('Running', cyan(cmd) + '...');
const output = getStdout(cmd).trim();

It turns out that bundlesize uses the iltorb library, which on Mac, requires Xcode to be installed on the device.

Since calls to npx foo don't need foo to be listed in package.json, we can remove bundlesize from package.json. This should mitigate the requirement of Xcode on mac laptops and make initial setup easier.

Fixes #19048
Closes #20775

@rsimha
Copy link
Contributor Author

rsimha commented Feb 11, 2019

@rsimha
Copy link
Contributor Author

rsimha commented Feb 11, 2019

Bundle size check on Travis looks good: https://travis-ci.org/ampproject/amphtml/jobs/491814430#L673-L679

Merging this after green build appears.

@danielrozenberg
Copy link
Member

And this works locally too? Sorcery!

@rsimha rsimha merged commit 2535e2f into ampproject:master Feb 11, 2019
@rsimha rsimha deleted the 2019-02-11-RemoveBundlesize branch February 11, 2019 20:44
noranazmy pushed a commit to noranazmy/amphtml that referenced this pull request Mar 22, 2019
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.

None yet

4 participants