File tree Expand file tree Collapse file tree 4 files changed +26
-19
lines changed Expand file tree Collapse file tree 4 files changed +26
-19
lines changed Original file line number Diff line number Diff line change 5
5
runs-on : ubuntu-latest
6
6
strategy :
7
7
matrix :
8
- node : [ '12 ', '14 ', '16 ' ]
8
+ node : [ '14 ', '16 ', '18 ' ]
9
9
name : Node ${{ matrix.node }} sample
10
10
steps :
11
11
- uses : actions/checkout@v2
Original file line number Diff line number Diff line change
1
+ ![ Tests] ( https://github.com/monade/eslint-plugin-angular/actions/workflows/test.yml/badge.svg )
2
+ [ ![ npm version] ( https://badge.fury.io/js/@monade%2Feslint-plugin-angular.svg )] ( https://badge.fury.io/js/@monade%2Feslint-plugin-angular )
3
+
1
4
# @monade/eslint-plugin-angular
2
5
A couple of quality-of-life eslint rules for Angular components.
3
6
@@ -30,10 +33,13 @@ Add to your .eslint.js:
30
33
31
34
## TODO:
32
35
* Document rules
33
- * When strategy is OnPush, show an error if there's a non-scalar property that is not ReadOnly<>
36
+ * [ Rule] When strategy is OnPush, show an error if there's a non-scalar property that is not ReadOnly<>
37
+ * [ Rule] Component too long
38
+ * [ Rule] Suggest strategy OnPush when the component is in the "components" folder
39
+ * [ Rule] ADVANCED: Check if there's a reactivity bug with changeDetection: OnPush
34
40
35
- ## Debugging
36
- You can use an AST view tool
41
+ ## Contributing
42
+ You can use an AST view tool to debug the structure of some code parts:
37
43
* For Javascript: https://astexplorer.net/
38
44
* For Typescript: https://ts-ast-viewer.com/
39
45
Original file line number Diff line number Diff line change 1
1
{
2
- "name" : " @monade/eslint-plugin-angular" ,
3
- "version" : " 1.0 .0" ,
4
- "description" : " A couple of rules for eslint + angular" ,
5
- "main" : " src/index.js" ,
6
- "scripts" : {
7
- "test" : " mocha"
8
- },
9
- "author" : " Mònade" ,
10
- "license" : " MIT" ,
11
- "devDependencies" : {
12
- "@typescript-eslint/parser" : " ^5.35.1" ,
13
- "eslint" : " ^8.22.0" ,
14
- "mocha" : " ^10.0.0" ,
15
- "typescript" : " ^4.7.4"
16
- }
2
+ "name" : " @monade/eslint-plugin-angular" ,
3
+ "version" : " 0.1 .0" ,
4
+ "description" : " A couple of quality-of-life rules for eslint + angular" ,
5
+ "main" : " src/index.js" ,
6
+ "scripts" : {
7
+ "test" : " mocha"
8
+ },
9
+ "author" : " Mònade" ,
10
+ "license" : " MIT" ,
11
+ "devDependencies" : {
12
+ "@typescript-eslint/parser" : " ^5.35.1" ,
13
+ "eslint" : " ^8.22.0" ,
14
+ "mocha" : " ^10.0.0" ,
15
+ "typescript" : " ^4.7.4"
16
+ }
17
17
}
Original file line number Diff line number Diff line change @@ -29,6 +29,7 @@ module.exports = {
29
29
return ;
30
30
}
31
31
32
+ /** @type {import('estree').MethodDefinition } */
32
33
const constructor = node . body . body . find (
33
34
( e ) => e . kind === "constructor"
34
35
) ;
You can’t perform that action at this time.
0 commit comments