Skip to content

Commit 0908f60

Browse files
committed
fix: duplicate svg id
1 parent 7e0012e commit 0908f60

File tree

8 files changed

+1759
-31
lines changed

8 files changed

+1759
-31
lines changed

.eslintrc.json

+7-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
11
{
2-
"extends": "@antfu"
2+
"extends": "@antfu",
3+
"env": {
4+
"jest": true
5+
},
6+
"plugins": [
7+
"jest"
8+
]
39
}

jest.config.js

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
module.exports = {
2+
roots: [
3+
'<rootDir>/test',
4+
],
5+
testMatch: [
6+
'**/__tests__/**/*.+(ts|tsx|js)',
7+
'**/?(*.)+(spec|test).+(ts|tsx|js)',
8+
],
9+
transform: {
10+
'^.+\\.(ts|tsx)$': 'ts-jest',
11+
}
12+
}

package.json

+6-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@
6161
"example:dev": "npm -C examples/vite-vue3 run dev",
6262
"lint": "eslint --ext .ts,.js,.vue",
6363
"prepublishOnly": "npm run build",
64-
"release": "npx bumpp --commit --tag --push && npm publish"
64+
"release": "npx bumpp --commit --tag --push && npm publish",
65+
"test": "jest"
6566
},
6667
"dependencies": {
6768
"@antfu/install-pkg": "^0.1.0",
@@ -78,14 +79,18 @@
7879
"@iconify/types": "^1.0.9",
7980
"@svgr/core": "^5.5.0",
8081
"@types/debug": "^4.1.7",
82+
"@types/jest": "^27.0.2",
8183
"@types/node": "^16.10.2",
8284
"@typescript-eslint/eslint-plugin": "^4.32.0",
8385
"@vue/compiler-sfc": "^3.2.19",
8486
"bumpp": "^7.1.1",
8587
"cross-env": "^7.0.3",
8688
"eslint": "^7.32.0",
89+
"eslint-plugin-jest": "^24.5.2",
8790
"esno": "^0.10.0",
91+
"jest": "^27.2.4",
8892
"rollup": "^2.58.0",
93+
"ts-jest": "^27.0.5",
8994
"tsup": "^5.2.1",
9095
"typescript": "^4.4.3",
9196
"vite": "^2.6.2"

0 commit comments

Comments
 (0)