Skip to content

Commit

Permalink
fix: bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Airkro committed Dec 4, 2023
1 parent c162479 commit 3ed2ad2
Show file tree
Hide file tree
Showing 4 changed files with 200 additions and 150 deletions.
4 changes: 3 additions & 1 deletion lib/handle-script/plugins.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ function readConfig() {
} = getPkg();

return parseImportGroups(
internalRegex ? [...config, internalRegex] : config,
internalRegex
? [...(Array.isArray(config) ? config : [config]), internalRegex]
: config,
);
} catch {
return [];
Expand Down
12 changes: 9 additions & 3 deletions lib/utils/lib.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,15 @@ export function parseImportGroups(config) {
'^ahooks\\/?',
'^ahooks-vue\\/?',
],
['^vant\\/?', '@vant\\/'],
['@element-plus', 'element-plus', 'element-ui'],
['^@docusaurus\\/'],
['^vant\\/?', '^@vant\\/'],
['@tarojs\\/'],
['^@element-plus', 'element-plus', 'element-ui'],
[
'^@docusaurus\\/',
'^@theme\\/',
'^@theme-original\\/',
'^@generated\\/',
],
'^echarts\\/?',
'@src\\/',
);
Expand Down
14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "garou",
"version": "0.6.19",
"version": "0.6.20",
"description": "Do thing what heroes didn't do",
"license": "MIT",
"author": {
Expand Down Expand Up @@ -52,7 +52,7 @@
"test": "ava --fail-fast"
},
"dependencies": {
"@typescript-eslint/parser": "^6.11.0",
"@typescript-eslint/parser": "^6.13.1",
"@yarnpkg/lockfile": "^1.1.0",
"eslint-module-utils": "^2.8.0",
"flat-cache": "^3.2.0",
Expand All @@ -71,20 +71,20 @@
"ava": "^5.3.1",
"best-shot": "^0.4.6",
"cheetor": "^0.13.0",
"eslint": "^8.53.0",
"eslint": "^8.55.0",
"eslint-plugin-ava": "^14.0.0",
"eslint-plugin-import": "^2.29.0",
"eslint-plugin-markdown": "^3.0.1",
"eslint-plugin-react": "^7.33.2",
"eslint-plugin-simple-import-sort": "^10.0.0",
"eslint-plugin-sort-class-members": "^1.19.0",
"eslint-plugin-vue": "^9.18.1",
"eslint-plugin-vue": "^9.19.2",
"espree": "^9.6.1",
"fs-chain": "^8.2.3",
"globby": "^13.2.2",
"micromatch": "^4.0.5",
"object-traversal": "^1.0.1",
"postcss": "^8.4.31",
"postcss": "^8.4.32",
"postcss-html": "^1.5.0",
"postcss-less": "^6.0.0",
"postcss-markdown": "^1.2.0",
Expand All @@ -103,7 +103,7 @@
"yarn-deduplicate": "^6.0.2"
},
"peerDependencies": {
"eslint": "^8.53.0",
"eslint": "^8.55.0",
"typescript": "^5.2.2"
},
"peerDependenciesMeta": {
Expand All @@ -118,7 +118,7 @@
"access": "public",
"registry": "https://registry.npmjs.org/"
},
"packageManager": "pnpm@8.10.4",
"packageManager": "pnpm@8.11.0",
"ava": {
"ignoredByWatcher": [
"**/temp/**"
Expand Down
Loading

0 comments on commit 3ed2ad2

Please sign in to comment.