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.

Ask HN: How to present new code-styleguide to colleagues?

1 pointsby igvadaimonabout 10 years ago
Frontend department at our company is growing fast, people are working in small teams, but our CSS&#x2F;HTML is still a mess. I decided to organize a small workshop and present some basic rules: html5 elements, no greedy selectors, no ids, extensibility, flexibility and so on.<p>The question is how to enforce those rules without getting rejection and hate from other developers?

1 comment

Phospheroabout 10 years ago
Instead of enforcing them and making it a top-down decision, make it a discussion where everyone has input. If the CSS&#x2F;HTML is really a mess, then everyone probably knows it and has to work with it every day.<p>See if you can come up with an estimate for how much of a time suck the bad practices actually create, and how much extra time it would take for people to actually do it correctly the first time. If you put it to them as &quot;You can spend 10 minutes now, or an hour later when you come back later and have no idea what&#x27;s going on&quot;, they&#x27;ll probably be a bit more receptive.<p>Come in with a set of standards - then ask for objections &#x2F; suggestions and make it a collaborative effort. Be prepared to defend your choices, and allow others to defend theirs as well.<p>Is there anything like checkstyle for HTML? (I work in Java, and our team uses it to enforce style guidelines) The easier it is for people to follow the rules, the more likely they are to actually do so.