-
-
Notifications
You must be signed in to change notification settings - Fork 337
feat(chore): add lint using CI #2501
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
Merged
Merged
Changes from all commits
Commits
Show all changes
39 commits
Select commit
Hold shift + click to select a range
6d1cec4
Unify CS and add CI linter
mvorisek 96c4258
add semi rule
mvorisek 512e134
fix semi indent
mvorisek 3898a44
fix semi with (var|const|let) regex
mvorisek 9eecf41
add no-trailing-spaces rule
mvorisek 5162e9c
manual review/fixes of regex replace
mvorisek 82d922c
add brace-style rule
mvorisek 6db0cf1
manual fixes
mvorisek c04d00c
add keyword-spacing rule
mvorisek 2c09b16
add space-in-parens rule
mvorisek 3247296
add padded-blocks rule
mvorisek 746e670
add comma-spacing rule
mvorisek 11795f3
add space-before-function-paren rule
mvorisek fedc0d2
add no-multiple-empty-lines rule
mvorisek cc5bad2
add space-infix-ops rule
mvorisek 2b3ff7d
add no-multi-spaces rule
mvorisek c39323b
add padding-line-between-statements rule
mvorisek 817c0fd
add spaced-comment rule /w manual changes
mvorisek 8ec531f
review all comments indent
mvorisek 9d7e49d
semi on a NL for chained & multiline calls
mvorisek 7360cca
semi on a NL for chained & multiline calls II.
mvorisek bd02237
-1 ident for "$allModules.each"
mvorisek 4fcc8e9
semi on a NL for chained & multiline calls III.
mvorisek aa0be27
fix multiline operator not indented
mvorisek b139f75
add quote-props rule
mvorisek 14879ba
add object-curly-spacing rule
mvorisek bc14eef
add space-before-blocks rule
mvorisek 8173058
add arrow-parens rule
mvorisek 0c8a278
add object-shorthand rule
mvorisek f4b3da6
add array-bracket-spacing rule
mvorisek c8e23b9
add dot-notation rule
mvorisek 087cf9b
fix tool import/order and import/no-useless-path-segments rules
mvorisek 7821837
add one-var-declaration-per-line rule
mvorisek 9c1bba5
add function-paren-newline rule
mvorisek a724525
fix tasks manually
mvorisek 45ebf65
add computed-property-spacing rule
mvorisek 81eefc4
add object-curly-newline rule
mvorisek aad8a53
add operator-linebreak rule
mvorisek ef5639d
add comma-style rule
mvorisek File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
module.exports = { | ||
env: { | ||
browser: true, | ||
es6: true, | ||
}, | ||
extends: [ | ||
], | ||
parserOptions: { | ||
ecmaVersion: '2020', | ||
sourceType: 'module', | ||
}, | ||
ignorePatterns: [ | ||
'/dist', | ||
'/examples/assets/library', | ||
'/test/coverage', | ||
'/test/helpers', | ||
], | ||
rules: { | ||
indent: ['error', 4, { SwitchCase: 1 }], | ||
'keyword-spacing': ['error'], | ||
'space-in-parens': ['error'], | ||
'comma-spacing': ['error'], | ||
'comma-style': ['error', 'last', { | ||
// https://github.com/airbnb/javascript/blob/eslint-config-airbnb-v19.0.4/packages/eslint-config-airbnb-base/rules/style.js#L54 | ||
exceptions: { | ||
ArrayExpression: false, | ||
ArrayPattern: false, | ||
ArrowFunctionExpression: false, | ||
CallExpression: false, | ||
FunctionDeclaration: false, | ||
FunctionExpression: false, | ||
ImportDeclaration: false, | ||
ObjectExpression: false, | ||
ObjectPattern: false, | ||
VariableDeclaration: false, | ||
NewExpression: false, | ||
}, | ||
}], | ||
'space-before-function-paren': ['error', { | ||
named: 'never', | ||
anonymous: 'always', | ||
asyncArrow: 'always', | ||
}], | ||
'space-infix-ops': ['error'], | ||
'array-bracket-spacing': ['error', 'never'], | ||
'object-curly-spacing': ['error', 'always'], | ||
'computed-property-spacing': ['error', 'never'], | ||
'space-before-blocks': ['error'], | ||
'one-var-declaration-per-line': ['error', 'always'], | ||
'function-paren-newline': ['error', 'multiline-arguments'], | ||
'padding-line-between-statements': ['error', { | ||
blankLine: 'always', | ||
prev: '*', | ||
next: ['continue', 'break', 'export', 'return', 'throw'], | ||
}], | ||
'spaced-comment': ['error', 'always', { | ||
line: { | ||
markers: ['/'], | ||
exceptions: ['-', '+'], | ||
}, | ||
block: { | ||
markers: ['!'], | ||
exceptions: ['*'], | ||
balanced: true, | ||
}, | ||
}], | ||
'padded-blocks': ['error', 'never'], | ||
'no-multiple-empty-lines': ['error', { | ||
max: 1, | ||
maxBOF: 0, | ||
maxEOF: 0, | ||
}], | ||
'no-multi-spaces': ['error', { | ||
exceptions: { | ||
Property: true, | ||
VariableDeclarator: true, | ||
}, | ||
}], | ||
'brace-style': ['error'], | ||
curly: ['error'], | ||
'object-shorthand': ['error', 'never'], | ||
'object-curly-newline': ['error', { | ||
// https://github.com/airbnb/javascript/blob/eslint-config-airbnb-v19.0.4/packages/eslint-config-airbnb-base/rules/style.js#L395 | ||
ObjectExpression: { minProperties: 4, multiline: true, consistent: true }, | ||
ObjectPattern: { minProperties: 4, multiline: true, consistent: true }, | ||
ImportDeclaration: { minProperties: 4, multiline: true, consistent: true }, | ||
ExportDeclaration: { minProperties: 4, multiline: true, consistent: true }, | ||
}], | ||
'operator-linebreak': ['error', 'before', { overrides: { '=': 'none' } }], | ||
'dot-notation': ['error', { allowKeywords: true }], | ||
'arrow-parens': ['error'], | ||
quotes: ['error', 'single', { avoidEscape: true }], | ||
'quote-props': ['error', 'as-needed', { | ||
keywords: false, | ||
numbers: false, | ||
}], | ||
'comma-dangle': ['error', { | ||
arrays: 'always-multiline', | ||
objects: 'always-multiline', | ||
functions: 'never', | ||
imports: 'always-multiline', | ||
exports: 'always-multiline', | ||
}], | ||
semi: ['error'], | ||
'no-extra-semi': ['error'], | ||
'no-trailing-spaces': ['error'], | ||
}, | ||
reportUnusedDisableDirectives: true, | ||
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
$(document) | ||
.ready(function() { | ||
// add popup to show name | ||
$('.ui:not(.container, .grid)').each(function() { | ||
$(this) | ||
.popup({ | ||
on : 'hover', | ||
variation : 'small inverted', | ||
exclusive : true, | ||
content : $(this).attr('class') | ||
}) | ||
; | ||
}); | ||
}) | ||
.ready(function () { | ||
// add popup to show name | ||
$('.ui:not(.container, .grid)').each(function () { | ||
$(this) | ||
.popup({ | ||
on: 'hover', | ||
variation: 'small inverted', | ||
exclusive: true, | ||
content: $(this).attr('class'), | ||
}) | ||
; | ||
}); | ||
}) | ||
; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.