-
-
Notifications
You must be signed in to change notification settings - Fork 78.8k
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
Using .glyphicon .glyphicon-
is cruel and unusual punishment
#10201
Comments
Not gonna happen until at least v4, and that's not coming anytime soon.
Not really a huge deal, nor a valid criticism in my opinion worth investing in further. Typing is pretty easy :). To make it even easier, check out if your editor has zen coding abilities—makes for super fast markup writing.
Find and replace works wonders. Also, you can customize the download to remove them or recompile your own version locally if you like.
In the grand scheme of things, this isn't an issue either. Your pages should be gzipped and as such those repeated strings basically get counted once. Overall, it comes down to performance. The attribute selectors we used in 2.x just don't cut it in larger projects and classes are way more performant. It also fits with our base and modifier class approach elsewhere in the project. |
I totally agree with @appleifreak. The way you now chosen has the described harm without benefit. You taken a product name as class name, where you better use a semantic name. I can not see a technical reason for that. To solve the performance problem and the base + modifier class approach, the only needed change was: add a class "icon". The usage than would be:
Please rollback the bondage to use "glyphicon". |
I add this question : why exposing icon provider in BS3 in the end-developper code? I guess for adding a BS4 upgrade guide row. |
Can the prefix be made configurable using a variable? Font Awesome already does this. |
👎 |
I'm sure some where along the line there was a discussion about how icon classes should be declared, but how the current format was decided on is beyond me.
.icon-
I believe it would be in the best interest of the Bootstrap community to start a serious discussion on standardizing the icon class names. More for than just for Bootstrap, too. Font-Awesome and the other icons-as-a-font libraries would benefit from standardization as well.
To me, it seems natural to stick to Bootstrap 2.x, (just
.icon-
), however extending with an extra.icon
before it would also be better than the existing implementation.The text was updated successfully, but these errors were encountered: