@ripple-ts/eslint-parser 0.3.10 → 0.3.12
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 +10 -9
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
[](https://www.npmjs.com/package/@ripple-ts/eslint-parser)
|
|
4
4
|
[](https://www.npmjs.com/package/@ripple-ts/eslint-parser)
|
|
5
5
|
|
|
6
|
-
ESLint parser for Ripple
|
|
7
|
-
and lint `.
|
|
6
|
+
ESLint parser for Ripple component files. This parser enables ESLint to understand
|
|
7
|
+
and lint `.tsrx` files by default, while also supporting `.ripple` files through
|
|
8
|
+
Ripple's built-in compiler.
|
|
8
9
|
|
|
9
10
|
## Installation
|
|
10
11
|
|
|
@@ -29,7 +30,7 @@ import ripplePlugin from '@ripple-ts/eslint-plugin';
|
|
|
29
30
|
|
|
30
31
|
export default [
|
|
31
32
|
{
|
|
32
|
-
files: ['**/*.ripple'],
|
|
33
|
+
files: ['**/*.{tsrx,ripple}'],
|
|
33
34
|
languageOptions: {
|
|
34
35
|
parser: rippleParser,
|
|
35
36
|
},
|
|
@@ -49,7 +50,7 @@ export default [
|
|
|
49
50
|
{
|
|
50
51
|
"overrides": [
|
|
51
52
|
{
|
|
52
|
-
"files": ["*.ripple"],
|
|
53
|
+
"files": ["*.tsrx", "*.ripple"],
|
|
53
54
|
"parser": "@ripple-ts/eslint-parser",
|
|
54
55
|
"plugins": ["ripple"],
|
|
55
56
|
"extends": ["plugin:ripple/recommended"]
|
|
@@ -60,14 +61,14 @@ export default [
|
|
|
60
61
|
|
|
61
62
|
## How It Works
|
|
62
63
|
|
|
63
|
-
This parser uses Ripple's compiler (`ripple/compiler`) to parse
|
|
64
|
-
into an ESTree-compatible AST that ESLint can analyze. The Ripple compiler
|
|
65
|
-
outputs ESTree-compliant ASTs, making integration straightforward.
|
|
64
|
+
This parser uses Ripple's compiler (`ripple/compiler`) to parse Ripple component
|
|
65
|
+
files into an ESTree-compatible AST that ESLint can analyze. The Ripple compiler
|
|
66
|
+
already outputs ESTree-compliant ASTs, making integration straightforward.
|
|
66
67
|
|
|
67
68
|
The parser:
|
|
68
69
|
|
|
69
70
|
1. Loads the Ripple compiler
|
|
70
|
-
2. Parses the `.
|
|
71
|
+
2. Parses the component source code (`.tsrx` or `.ripple`)
|
|
71
72
|
3. Returns the ESTree AST to ESLint
|
|
72
73
|
4. Allows ESLint rules to analyze Ripple-specific patterns
|
|
73
74
|
|
|
@@ -84,7 +85,7 @@ The parser supports all Ripple syntax including:
|
|
|
84
85
|
|
|
85
86
|
## Example
|
|
86
87
|
|
|
87
|
-
Given a `.
|
|
88
|
+
Given a `.tsrx` file:
|
|
88
89
|
|
|
89
90
|
```ripple
|
|
90
91
|
import { track } from 'ripple';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ripple-ts/eslint-parser",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.12",
|
|
4
4
|
"description": "ESLint parser for Ripple (.ripple files)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"@types/node": "^24.3.0",
|
|
40
40
|
"tsdown": "^0.20.3",
|
|
41
41
|
"typescript": "^5.9.3",
|
|
42
|
-
"ripple": "0.3.
|
|
42
|
+
"ripple": "0.3.12"
|
|
43
43
|
},
|
|
44
44
|
"engines": {
|
|
45
45
|
"node": ">=20.0.0"
|