-
-
Notifications
You must be signed in to change notification settings - Fork 181
Support custom configuration file #225
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
Comments
Agreed. It would be nice to have a Thanks for the great tool! |
Would love this feature too. I'm currently working on a project that makes heavy use of code splitting and produces about 10 different chunks at build time. I've set up bundlesize to check each chunk against a specific limit, with different compressions, which is great. The downside is that my package.json is now twice as big due to this. It would be fantastic to be able to call |
For example, right now I have an npm script that looks like this: "size": "bundlesize -f './.next/main.js' -s 150kB" It would be nice if I could move all the config to a [
{
"path": "./.next/main.js",
"maxSize": "150kB"
}
] Then the npm script could simply be: "size": "bundlesize" |
Adding this should be very straight forward. https://github.com/davidtheclark/cosmiconfig can be added as a dependency, and it takes very few lines of code. @siddharthkp, I can take this on unless there is any objection to using this package. |
That would be awesome. cosmiconfig is what many other tools use. Prettier, for example: https://prettier.io/docs/en/configuration.html |
Have a custom config setting in this PR: In our monorepo we maintianed hundreds of individual bundles and the package.json got ugly 😊 |
Implemented in #316 and published in 0.18.0 🎉 Check out README for details |
Uh oh!
There was an error while loading. Please reload this page.
Do you want to request a feature or report a bug?
Request a feature
What is the current behavior?
Read the
package.json
If this is a feature request, what is motivation or use case for changing the behavior?
I want to separate configs into specific directory.
Please mention other relevant information.
The text was updated successfully, but these errors were encountered: