Closed tmcw closed 13 years ago
As I tear out the carpets on the layers branch I've been tweaking small bits of style but generally leaving things alone wherever possible. FWIW, the bits of code style I actually care about are mostly around dropped opening braces and avoiding anonymous function literals. Meaningful english words and whitespace! =)
Cool, I've made a lot of changes to style, and feel like this is cool to close. There are no extreme examples like dropped braces left at this point - probably a few anonymous function literals (guilty, I am)
This is kind of something that we should work on when we're near another 'major tag' so that people don't get tons of merge conflicts, but it'd be useful to start moving towards a predictable code style - there are bits where
map.js
starts adopting the K&R style and then returns to something more javascript-y.I've been using fixjsstyle and jshint for a quick hit of code-style enforcement on other projects. JSHint is a little severe, yelling at you for useful tricks, but basic stuff like spacing between variables, missing semicolons, etc., are handled pretty well by fixjsstyle.