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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion: Add an example for webpack.config.preset.js #2119

Closed
5 of 6 tasks
LubomirGeorgiev opened this issue Oct 19, 2018 · 1 comment
Closed
5 of 6 tasks

Suggestion: Add an example for webpack.config.preset.js #2119

LubomirGeorgiev opened this issue Oct 19, 2018 · 1 comment

Comments

@LubomirGeorgiev
Copy link
Contributor

LubomirGeorgiev commented Oct 19, 2018

Submit a feature request or bug report


Feature Request

Regarding #2083 I think it's a good idea to add a sample webpack.config.preset.js that shows people how to use this preset file to override the webpack config.

@knowler
Copy link
Member

knowler commented Oct 19, 2018

Are you suggesting adding an example file to the Sage default preset (i.e. what's in this repo)?

The purpose of this added feature was for the sake of roots/sage-installer. It allows for new and existing presets to modify webpack config without needing a full copy of it — which would be a maintenance nightmare. If you want to modify the webpack config, I would recommend just modifying it directly since Sage is a boilerplate, which means it's meant to be modified.

I'm going to close this for now, since an example file would encourage usage of this feature in a way that was not intended.

If you would like to use this feature for modification purposes, you can check out the Tailwind preset below:

https://github.com/roots/sage-installer/blob/master/src/Presets/stubs/Tailwind/build/webpack.config.preset.js

(This preset also overrides postcss.config.js)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants