Know the performance impact of including an npm package in your app's bundle.
- Works with ES6 packages
- Can build css and scss packages as well
- Reports historical trends
- Size in browser - As seen on package searches at yarnpkg.com
- bundlephobia-cli - A Command Line client for bundlephobia
- importcost - An Atom plugin to display size of imported packages
This error is thrown if a package require
s a dependency without adding it in its depdencies or peerDependencies list. In the absence of such a definition, we cannot reliably report the size of the package - since we cannot resolve any information about the package.
In such a case, it's best to report an issue with the package author asking the missing package to be added to its package.json
You can see a detailed stack trace in your devtools console, and open an issue with the relevant details. Working on a more ideal solution for this.
script | description |
---|---|
yarn run dev |
Start a development server locally |
yarn run build |
Build for production |
yarn run prod |
Start a production server locally |
Add a .env
file to the root with Algolia credentials. The server should still run without this, but some features might be disabled.
# App Id for NPM Registry
ALGOLIA_APP_ID=OFCNCOG2CU
# API Key
ALGOLIA_API_KEY=<api-key-obtained-from-algolia>
In addition, one can specify -
BUILD_SERVICE_ENDPOINT=<endpoint-to-service>
In the absence of such an endpoint, packages will be built locally using the getPackageStats
function
and
CACHE_SERVICE_ENDPOINT=<endpoint-to-service>
FIREBASE_API_KEY=<apiKey>
FIREBASE_AUTH_DOMAIN=<domain>
FIREBASE_DATABASE_URL=<url>
for caching to work (optional).