An ExpressJS App that generates and displays a chart of the bundle sizes history of compiled AMP files. It is deployed at https://amp-bundle-size-chart.appspot.com/
Unlike the other apps in this repository, this one was cobbled together quickly. If you would like to improve the code or documentation, please send us a pull request!
Required tools:
Steps:
- Clone this repository and cd into the
bundle-size-chartdirectory - Run
npm install - Create a user-based GitHub token with
public_repopermissions. - Create a file called
.envwith one line:(whereACCESS_TOKEN=[[GITHUB_ACCESS_TOKEN]][[GITHUB_ACCESS_TOKEN]]is the token generated in the previous step, without the square brackets.) - Create a Google AppEngine flexible NodeJS instance with a Google Cloud
Storage bucket
- When asked, set a uniform (no per-object ACL) access control on the storage bucket
- Add a
Storage Object Viewerpermission toallUserson the storage bucket
- Set the CORS permissions on the bucket to allow connections from your GAE
instance. Edit the
cors-json-file.jsonfile to add your GAE instance's.appspot.comdomain and run:gsutil cors set cors-json-file.json gs://[[CLOUD_STORAGE_BUCKET_NAME]] - Run
npm run deployandnpm run deploy-cronto deploy the app and cron job