@jeffcaradona/eslint-plugin-eta 0.2.2 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/lib/processors/eta.js +6 -9
- package/package.json +3 -3
- package/sonar-project.properties +15 -0
package/README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# eslint-plugin-eta
|
|
2
|
-
An ESLint plugin so you can lint Eta template files (forked from <https://github.com/bgub/eslint-plugin-eta>)
|
|
2
|
+
An ESLint plugin so you can lint Eta template files (forked from <https://github.com/bgub/eslint-plugin-eta>) with so much assistance from GitHub Copilot.
|
|
3
3
|
|
|
4
4
|
<span align="center">
|
|
5
5
|
|
package/lib/processors/eta.js
CHANGED
|
@@ -12,18 +12,15 @@ export default {
|
|
|
12
12
|
})
|
|
13
13
|
let result = eta.parse(text)
|
|
14
14
|
|
|
15
|
-
|
|
16
|
-
(res) => res.t === 'r' || res.t === 'i' || res.t === 'e'
|
|
17
|
-
|
|
15
|
+
const text_content = result
|
|
16
|
+
.filter((res) => res.t === 'r' || res.t === 'i' || res.t === 'e')
|
|
17
|
+
.map((res) => String(res.val))
|
|
18
|
+
.join('\n')
|
|
18
19
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
result = result.join('\n')
|
|
22
|
-
|
|
23
|
-
return [{ text: result, filename: _filename }]
|
|
20
|
+
return [{ text: text_content, filename: _filename }]
|
|
24
21
|
},
|
|
25
22
|
|
|
26
23
|
postprocess: (messages, _filename) => {
|
|
27
|
-
return
|
|
24
|
+
return messages.flat()
|
|
28
25
|
}
|
|
29
26
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jeffcaradona/eslint-plugin-eta",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "An ESLint plugin so you can lint Eta template files (forked from bgub/eslint-plugin-eta)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"license": "MIT",
|
|
24
24
|
"repository": {
|
|
25
25
|
"type": "git",
|
|
26
|
-
"url": "git+https://github.com/jeffcaradona/eslint-plugin-eta.git"
|
|
27
|
-
|
|
26
|
+
"url": "git+https://github.com/jeffcaradona/eslint-plugin-eta.git"
|
|
27
|
+
|
|
28
28
|
},
|
|
29
29
|
"peerDependencies": {
|
|
30
30
|
"eslint": ">=9 <10",
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
sonar.projectKey=jeffcaradona_eslint-plugin-eta
|
|
2
|
+
sonar.organization=xbe90seup2ltm6gwmugkq
|
|
3
|
+
|
|
4
|
+
# Project settings
|
|
5
|
+
sonar.projectName=eslint-plugin-eta
|
|
6
|
+
sonar.projectVersion=0.2.2
|
|
7
|
+
sonar.sourceEncoding=UTF-8
|
|
8
|
+
|
|
9
|
+
# Source code
|
|
10
|
+
sonar.sources=lib
|
|
11
|
+
sonar.tests=test
|
|
12
|
+
sonar.javascript.lcov.reportPaths=coverage/lcov.info
|
|
13
|
+
|
|
14
|
+
# Coverage
|
|
15
|
+
sonar.coverage.exclusions=lib/**/index.js
|