Web Coding Convention - boostcamp-2020/IssueTracker-13 GitHub Wiki
Filename Convention
ํ์ผ๋ช : (Upper)camelCase(JS) / UpperCamelCase(iOS)
ํด๋๋ช : camelCase(JS) / UpperCamelCase(iOS)
JavaScript Convention
Module Convention
Backend: CommonJS (require๋ฌธ)
Frontend: ES Module (import ~ export ~)
React
Airbnb React Convention ๋ฐ๋ฆ
EsLint Settings File
module.exports = {
'env': {
'browser': true,
'es6': true,
'node': true,
},
'extends': 'eslint:recommended',
'parserOptions': {
'ecmaVersion': 12,
'sourceType': 'module',
},
'rules': {
indent: ['error', 2],
'semi': ['error', 'always'],
'no-trailing-spaces': 'error',
curly: 'error',
'brace-style': 'error',
'no-multi-spaces': 'error',
'space-infix-ops': 'error',
'space-unary-ops': 'error',
'no-whitespace-before-property': 'error',
'func-call-spacing': 'error',
'space-before-blocks': 'error',
'keyword-spacing': ['error', { before: true, after: true }],
'comma-spacing': ['error', { before: false, after: true }],
'comma-style': ['error', 'last'],
'comma-dangle': ['error', 'always-multiline'],
'space-in-parens': ['error', 'never'],
'block-spacing': 'error',
'array-bracket-spacing': ['error', 'never'],
'object-curly-spacing': ['error', 'always'],
'key-spacing': ['error', { mode: 'strict' }],
'arrow-spacing': ['error', { before: true, after: true }],
'eol-last': 'error',
quotes: ['error', 'single'],
},
};
CSS Convention
lint ๊ท์น ํ์ํด์ง๋ฉด ์ถํ ๋ ผ์