@unocss/eslint-plugin 0.59.3 → 0.60.0
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/dist/index.cjs +11 -8
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.mjs +9 -6
- package/package.json +6 -6
package/dist/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
'use strict';
|
|
1
|
+
'use strict';
|
|
2
2
|
|
|
3
3
|
const MagicString = require('magic-string');
|
|
4
4
|
const node_path = require('node:path');
|
|
@@ -68,10 +68,11 @@ const orderAttributify = createRule({
|
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
70
|
};
|
|
71
|
-
|
|
71
|
+
const parserServices = context?.sourceCode.parserServices || context.parserServices;
|
|
72
|
+
if (parserServices == null || parserServices.defineTemplateBodyVisitor == null) {
|
|
72
73
|
return scriptVisitor;
|
|
73
74
|
} else {
|
|
74
|
-
return
|
|
75
|
+
return parserServices?.defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor);
|
|
75
76
|
}
|
|
76
77
|
}
|
|
77
78
|
});
|
|
@@ -135,10 +136,11 @@ const order = createRule({
|
|
|
135
136
|
}
|
|
136
137
|
}
|
|
137
138
|
};
|
|
138
|
-
|
|
139
|
+
const parserServices = context?.sourceCode.parserServices || context.parserServices;
|
|
140
|
+
if (parserServices == null || parserServices.defineTemplateBodyVisitor == null) {
|
|
139
141
|
return scriptVisitor;
|
|
140
142
|
} else {
|
|
141
|
-
return
|
|
143
|
+
return parserServices?.defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor);
|
|
142
144
|
}
|
|
143
145
|
}
|
|
144
146
|
});
|
|
@@ -216,10 +218,11 @@ const blocklist = createRule({
|
|
|
216
218
|
}
|
|
217
219
|
}
|
|
218
220
|
};
|
|
219
|
-
|
|
221
|
+
const parserServices = context?.sourceCode.parserServices || context.parserServices;
|
|
222
|
+
if (parserServices == null || parserServices.defineTemplateBodyVisitor == null) {
|
|
220
223
|
return scriptVisitor;
|
|
221
224
|
} else {
|
|
222
|
-
return
|
|
225
|
+
return parserServices?.defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor);
|
|
223
226
|
}
|
|
224
227
|
}
|
|
225
228
|
});
|
|
@@ -347,4 +350,4 @@ const index = {
|
|
|
347
350
|
}
|
|
348
351
|
};
|
|
349
352
|
|
|
350
|
-
exports
|
|
353
|
+
module.exports = index;
|
package/dist/index.d.cts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.mjs
CHANGED
|
@@ -62,10 +62,11 @@ const orderAttributify = createRule({
|
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
64
|
};
|
|
65
|
-
|
|
65
|
+
const parserServices = context?.sourceCode.parserServices || context.parserServices;
|
|
66
|
+
if (parserServices == null || parserServices.defineTemplateBodyVisitor == null) {
|
|
66
67
|
return scriptVisitor;
|
|
67
68
|
} else {
|
|
68
|
-
return
|
|
69
|
+
return parserServices?.defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor);
|
|
69
70
|
}
|
|
70
71
|
}
|
|
71
72
|
});
|
|
@@ -129,10 +130,11 @@ const order = createRule({
|
|
|
129
130
|
}
|
|
130
131
|
}
|
|
131
132
|
};
|
|
132
|
-
|
|
133
|
+
const parserServices = context?.sourceCode.parserServices || context.parserServices;
|
|
134
|
+
if (parserServices == null || parserServices.defineTemplateBodyVisitor == null) {
|
|
133
135
|
return scriptVisitor;
|
|
134
136
|
} else {
|
|
135
|
-
return
|
|
137
|
+
return parserServices?.defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor);
|
|
136
138
|
}
|
|
137
139
|
}
|
|
138
140
|
});
|
|
@@ -210,10 +212,11 @@ const blocklist = createRule({
|
|
|
210
212
|
}
|
|
211
213
|
}
|
|
212
214
|
};
|
|
213
|
-
|
|
215
|
+
const parserServices = context?.sourceCode.parserServices || context.parserServices;
|
|
216
|
+
if (parserServices == null || parserServices.defineTemplateBodyVisitor == null) {
|
|
214
217
|
return scriptVisitor;
|
|
215
218
|
} else {
|
|
216
|
-
return
|
|
219
|
+
return parserServices?.defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor);
|
|
217
220
|
}
|
|
218
221
|
}
|
|
219
222
|
});
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unocss/eslint-plugin",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.60.0",
|
|
5
5
|
"description": "ESLint plugin for UnoCSS",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -35,15 +35,15 @@
|
|
|
35
35
|
"node": ">=14"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@typescript-eslint/utils": "^7.
|
|
39
|
-
"magic-string": "^0.30.
|
|
38
|
+
"@typescript-eslint/utils": "^7.8.0",
|
|
39
|
+
"magic-string": "^0.30.10",
|
|
40
40
|
"synckit": "^0.9.0",
|
|
41
|
-
"@unocss/config": "0.
|
|
42
|
-
"@unocss/core": "0.
|
|
41
|
+
"@unocss/config": "0.60.0",
|
|
42
|
+
"@unocss/core": "0.60.0"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"vue-eslint-parser": "^9.4.2",
|
|
46
|
-
"@unocss/eslint-plugin": "0.
|
|
46
|
+
"@unocss/eslint-plugin": "0.60.0"
|
|
47
47
|
},
|
|
48
48
|
"scripts": {
|
|
49
49
|
"build": "unbuild",
|