Skip to content
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

Styleguide #5

Open
ilyar opened this issue Dec 8, 2013 · 3 comments
Open

Styleguide #5

ilyar opened this issue Dec 8, 2013 · 3 comments

Comments

@ilyar
Copy link
Contributor

ilyar commented Dec 8, 2013

Надо обсудить и утвердить docs/styleguide.md, есть предпочтение использовать два пробела indent_size = 2

@ilyar
Copy link
Contributor Author

ilyar commented Dec 8, 2013

как вариант который можно использовать https://github.com/felixge/node-style-guide
+1 за indent_size = 2

@qfox
Copy link
Member

qfox commented Dec 8, 2013

Смотрю joyent/node и visionmedia/express — ок. Поддерживаю вариант Феликса.
Единственный нюанс со вложенными closure — это scope. У него в стайлгайде это не описывается.
Например:

exports.init = function init (scopedVariable) {
  return {
    method: apiMethod
  };
  function apiMethod () {
    scopedVariable; // using inside another method
  };
};

@qfox
Copy link
Member

qfox commented Dec 8, 2013

Большую часть проверок можно описать в jscs, чего не хватает — Марат оперативно отвечает на issue, принимает PR.

@ilyar ilyar mentioned this issue Dec 12, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants