-
Notifications
You must be signed in to change notification settings - Fork 7
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
Style guide for workshoppers #37
Comments
While generally not a bad thought it is a very religious issue you are trying to kick off here. |
I'm less interested in a holy war than I am in consistency. Here's an example solution from expressworks: var express = require('express')
var app = express()
app.use(require('stylus').middleware(process.argv[3]));
app.use(express.static(process.argv[3]));
app.listen(process.argv[2]) While this is a trivial example the quality of the solution could be improved by running a simple linter over it. Given how NodeSchool presents itself and its workshoppers it makes sense that they would all be formatted similarly. The Go team summarized quite nicely on their blog where they outline the benefits consistently formatted code:
Put that way it really isn't terribly controversial. Making a decision at the workshopper level saves individual contributors from having to have these conversations or entertain style-based pull requests. For what it's worth npm will be using Standard moving forward. |
@mmwtsn I have no problem with coding standards. I just wanted to prepare you for the discussion you are bringing yourself into. |
Thoughts on adding a suggested style guide for the workshoppers source code?
I have been enjoying going through them but have found the code samples formatting inconsistent. It's not a huge deal but considering that this could be someone's first introduction to Node.js development it would be nice to be able to say "Hey, here's how we recommend you format your code."
Code style could be incorporated as an early lesson in
learnyounode
. This should be fairly straightforward for the user if an npm-distributed formatter is suggested like Standard.The text was updated successfully, but these errors were encountered: