Skip to content
This repository has been archived by the owner on Nov 16, 2023. It is now read-only.

Commit

Permalink
Merge pull request #15 from naver/eslint-4
Browse files Browse the repository at this point in the history
updates eslint version to 4.7.1

Closed #15 
Fixed #15
  • Loading branch information
sculove authored Sep 19, 2017
2 parents b57b1c9 + e910066 commit 5d8fb06
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"description": "Naver JavaScript Coding Conventions rules for eslint",
"main": "index.js",
"dependencies": {
"eslint": "^3.16.0",
"eslint-plugin-import": "^2.2.0"
"eslint": "^4.7.1",
"eslint-plugin-import": "^2.7.0"
},
"repository": {
"type": "git",
Expand Down
13 changes: 12 additions & 1 deletion rules/style.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ module.exports = {
// [NAVER] 7.8. 괄호 안에 공백을 삽입하지 않는다.(disallowSpacesInsideArrayBrackets, disallowSpacesInsideObjectBrackets, disallowSpacesInsideParentheses)
"array-bracket-spacing": ["error", "never"],

"array-element-newline": ["error", "never"],
"array-bracket-newline": ["error", {"multiline": true}],

// // enforce one true brace style
// [NAVER] 2.1 줄의 끝에서 중괄호 시작
"brace-style": "error",
Expand Down Expand Up @@ -100,7 +103,7 @@ module.exports = {

// allow/disallow an empty newline after var statement
// [NAVER] 5.2. 함수 선언 간, 변수 선언 후 빈 줄 사용 준수
"newline-after-var": ["error", "always"],
// "newline-after-var": ["error", "always"],
// "newline-after-var": "off",

// enforces new line after each method call in the chain to make it
Expand Down Expand Up @@ -186,6 +189,14 @@ module.exports = {
// [NAVER] 5.1 함수 선언 후 빈줄 사용 지양
"padded-blocks": ["error", "never"],

"padding-line-between-statements": ["error",
{ "blankLine": "any", "prev": "*", "next": "return" },
{ "blankLine": "always", "prev": ["const", "let"], "next": "*" },
{ "blankLine": "any", "prev": ["const", "let"], "next": ["const", "let"]},
{ "blankLine": "always", "prev": "directive", "next": "*" },
{ "blankLine": "never", "prev": "directive", "next": "directive" }
],

// require quotes around object literal property names
// http://eslint.org/docs/rules/quote-props.html
"quote-props": ["error", "as-needed", { keywords: false, unnecessary: false, numbers: false }],
Expand Down

0 comments on commit 5d8fb06

Please sign in to comment.