-
Notifications
You must be signed in to change notification settings - Fork 2
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
--environment=production
doesn't minify the generated class names
#7
Comments
This is something that just needs to be implimented. It's basically there, just needs to pull the config in properly. |
@boris-petrov @hoIIer Do either of you know what the prescribed way of bringing in the current "environment" is? Right now it's doing
which comes from registry.app.options.environment but that's showing up as undefined. (still is undefined when you fix the spelling issue). It looks like we can pull it out of the app, so registry.app.env` is set. But this is only set for the app, not addons.
Now we can grab the "host app" and set it from what that is, however, when it comes to embroider, this will be prebuilt, so will have to figure out how to properly set this value when an addon is "pre-built" with embroider. Do either of you know any addons that set configs based on the build time environment flag that are modern maintained addons? |
Not sure, perhaps ember-css-modules? |
I haven't seen what @dfreeman has done with the 2.0 version till just now. He did all the things that i was wanting to with adding the example apps and similar to the "plugin" model that this has adopted. i should sync up with him again about finding a path to were "css-modules" or "namespace" is aligned. His rewrite with using a complete registry implementation pattern is very similar as well. I know this really isn't the place for this discussion, but @dfreeman we should probably have that discussion sometime again. i'll never be able to support this addon as much cause i don't work on ember anymore. But the desire to have a progressive approach from "co located styles" the to branch to "style namespace" or "css modules" would be so beneficial to the community... Anyway... I'll look into the best way to pull in the environment. Sorry for that side rabbit trail. |
The plugin registry system actually landed in our 0.x days back in 2017 😄 IMO while the registry made sense at the time and has had some useful applications, I think today these sorts of bespoke build systems are detrimental to the effort to move toward more ecosystem-standard tools that allow for front-loading most of the work to publish time rather than forcing host apps to repeat work to build all their dependencies. With an eye toward Embroider and the v2 package spec, I'm actively working to move away from anything like a shared core Ember-specific style processing layer in favor of having folks directly use tools from the broader Web-dev ecosystem 🙂 If things shake out the way I expect, the future of |
@dfreeman hmmm.. that makes sense. So people would just use the Hmm. I guess that works. CSS is in such a weird place these days anyway. soo.. 🤷 😞 |
I would expect that option to do that (it did in
ember-component-css
). Explicitly passingterseClassNames
inember-cli-build.js
like so:Also doesn't seem to have an effect.
The text was updated successfully, but these errors were encountered: