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

Provide exclude glob option #282

Open
arei opened this issue May 19, 2022 · 1 comment
Open

Provide exclude glob option #282

arei opened this issue May 19, 2022 · 1 comment

Comments

@arei
Copy link

arei commented May 19, 2022

Currently when processing our application, ember-css-modules, concats all the *.css files into a single file. This includes app/styles/*.css. Unfortunately, it seems to do it in whatever order it wants and with regards to things like @import. Thus we end up with an output file that has all of our component css files at the top and our app/styles/*.css at the bottom, apparently in alphabetical order. such that app.css comes before reset.css, which is problematic.

And headerModules doesnt seem to have an impact.

And importing via @import statements just lands us two copies of the css file being included.

So, unless we're doing something wrong, I think we need a way to control what files ember-css-modules includes and possibly in what order they are included.

Our config, for reference:

		cssModules: {
			generateScopedName(className, modulePath) {
				return className;
			},
			headerModules: [
				'app/styles/reset',
				'app/styles/toasts',
				'app/styles/tooltips',
				'app/styles/spinkit',
				'app/styles/ember-power-calendar',
			],
			plugins: [
				require('postcss-reporter')(),
				require('postcss-import')(),
				require('postcss-preset-env')({
					stage: 0,
				}),
			],
		},

@optikalefx

@optikalefx
Copy link

Bump, is there anyone who can look at this?

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