TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

A Tale of Two Bootstraps: Lessons Learned in Maintainable CSS

71 pointsby timfover 12 years ago

5 comments

spionover 12 years ago
My takeaway from this story is slightly different - we need better tools. Especially better refactoring tools.<p>IMO, using larger names is only a symptom of the main problem - the fact that we're still using plain old text search and replace. We're relying on it way too much. And its not a very precise, very fine tool.<p>Code organization solutions don't seem to fully solve this either.<p>1) Whoops, we need to change this style everywhere:<p>"Lets just use classes, then when we want to change the style of our buttons we can change it at a single place (the class)"<p>2) Whoops, we need to change the class name<p>"Lets just use templates containing the class name, then when we want to change the class name we simply change it in the template"<p>3) Whoops, we need to change the template... and so on.<p>I think there is a clear need for better code maintenance tools, for all languages. Especially the search (and replace) problem. Perhaps search tools that are based on the language parsers would help.
评论 #4930942 未加载
评论 #4930719 未加载
daigoba66over 12 years ago
Is it possible that bootstrap was really only designed to "bootstrap" the design of a web project? I think that eventually the project will mature into its own. I would not expect a mature project to ever "upgrade" to a new version of bootstrap as that doesn't really make sense to me.
评论 #4930439 未加载
评论 #4930877 未加载
评论 #4930845 未加载
waxjarover 12 years ago
&#62; For a longer article that also recommends that technique for semantic more than maintenance reasons, read Stop Embedding Bootstrap Classes in your HTML.<p>I feel so dumb for never having thought of this myself. It really irked me that my HTML was no longer semantic, which is why I putted off using Bootstrap for a very long time. I don't have to feel guilty any more :P
stagasover 12 years ago
I feel like all the tools that allow you to do X or Y faster, actually make maintainability and debugging magnitudes slower.<p>Which is why I've started avoiding anything I feel it's going to be difficult to read and maintain in the future by me or another person. I now always assume it's going to be another person, even if it's not, but this has helped me write more clear and concise code.<p>Even if the initial effort is more time consuming, it makes up for it in the end. Bootstrap and CoffeeScript are two tools that I feel suffer from that effect greatly.<p>Maybe it's a fallacy, because I have nothing to back my claims, but it's only my personal opinion, feel free to use whatever makes you happy.
Beckhamover 12 years ago
coursera.org passes the first test of a successful Bootstrap site: i've visited dozens of times and didn't know it was Bootstrap!