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

[Feature Request] Discuss removing BEM mixins in new Chalk Theme #7136

Closed
wguldin opened this issue Sep 20, 2017 · 1 comment
Closed

[Feature Request] Discuss removing BEM mixins in new Chalk Theme #7136

wguldin opened this issue Sep 20, 2017 · 1 comment

Comments

@wguldin
Copy link

wguldin commented Sep 20, 2017

Existing Component

Yes

Component Name

global

Description

Hi,

As a web designer who writes a ton of scss, I'm excited to see element move toward SCSS in your newest 'carbon' branch! In that branch, I would like to discuss a change introduced in #6643.

For several reasons, I think it might be desirable for element-ui to use a more traditional BEM naming setup, where class names are written out in the source code directly. I noticed this problem with the current setup in master as well. SCSS mixins are certainly an improvement over the post-css bem plugin (because it is easier to figure out what is going on), but it still has some drawbacks, including:

  • Source code discoverability. If you inspect an element, see a class, and then try to find the resulting class in the source code, it is difficult because the name is being dynamically generated.
  • Disconnect between authored scss and finally output css.
  • The tradeoff here is loss of development speed, in that you could write selectors faster with this setup. I think clarity with class names and what not would be a good tradeoff and encourage adoption of the framework.

I'm sure there are good reasons for your current approach, and perhaps there is some tooling that would solve these issues, but I wanted to bring it up.

Thanks for making a great library!

@stale
Copy link

stale bot commented Feb 18, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Feb 18, 2019
@stale stale bot closed this as completed Feb 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants