@unocss/eslint-plugin 0.51.2 → 0.51.4
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/worker-sort.cjs +3 -1
- package/dist/worker-sort.mjs +3 -1
- package/package.json +4 -4
package/dist/worker-sort.cjs
CHANGED
|
@@ -32,7 +32,9 @@ async function sortRules(rules, uno) {
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
async function getGenerator() {
|
|
35
|
-
const { config: config$1 } = await config.loadConfig();
|
|
35
|
+
const { config: config$1, sources } = await config.loadConfig();
|
|
36
|
+
if (!sources.length)
|
|
37
|
+
throw new Error("[@unocss/eslint-plugin] No config file found, create a `uno.config.ts` file in your project root and try again.");
|
|
36
38
|
return core.createGenerator(config$1);
|
|
37
39
|
}
|
|
38
40
|
let promise;
|
package/dist/worker-sort.mjs
CHANGED
|
@@ -30,7 +30,9 @@ async function sortRules(rules, uno) {
|
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
async function getGenerator() {
|
|
33
|
-
const { config } = await loadConfig();
|
|
33
|
+
const { config, sources } = await loadConfig();
|
|
34
|
+
if (!sources.length)
|
|
35
|
+
throw new Error("[@unocss/eslint-plugin] No config file found, create a `uno.config.ts` file in your project root and try again.");
|
|
34
36
|
return createGenerator(config);
|
|
35
37
|
}
|
|
36
38
|
let promise;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unocss/eslint-plugin",
|
|
3
|
-
"version": "0.51.
|
|
3
|
+
"version": "0.51.4",
|
|
4
4
|
"description": "ESLint plugin for UnoCSS",
|
|
5
5
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -39,11 +39,11 @@
|
|
|
39
39
|
"@typescript-eslint/utils": "^5.57.1",
|
|
40
40
|
"magic-string": "^0.30.0",
|
|
41
41
|
"synckit": "^0.8.5",
|
|
42
|
-
"@unocss/config": "0.51.
|
|
43
|
-
"@unocss/core": "0.51.
|
|
42
|
+
"@unocss/config": "0.51.4",
|
|
43
|
+
"@unocss/core": "0.51.4"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"@unocss/eslint-plugin": "0.51.
|
|
46
|
+
"@unocss/eslint-plugin": "0.51.4"
|
|
47
47
|
},
|
|
48
48
|
"scripts": {
|
|
49
49
|
"build": "unbuild",
|