Skip to content

Commit d98ed07

Browse files
authored
chore: father 4 and rc-test (#538)
* chore: father 4 and rc-test * Update package.json
1 parent 9e66b09 commit d98ed07

File tree

3 files changed

+22
-19
lines changed

3 files changed

+22
-19
lines changed

.fatherrc.js

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
1-
export default {
2-
cjs: 'babel',
3-
esm: { type: 'babel', importLibToEs: true },
4-
preCommit: {
5-
eslint: true,
6-
prettier: true,
7-
},
8-
runtimeHelpers: true,
9-
};
1+
import { defineConfig } from 'father';
2+
3+
export default defineConfig({
4+
plugins: ['@rc-component/father-plugin'],
5+
});

package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,15 @@
3232
],
3333
"scripts": {
3434
"compile": "father build && lessc assets/index.less assets/index.css",
35-
"coverage": "father test --coverage",
35+
"coverage": "rc-test --coverage",
3636
"docs:build": "dumi build",
3737
"docs:deploy": "gh-pages -d .doc",
3838
"lint": "eslint src/ --ext .tsx,.ts,.jsx,.js",
3939
"now-build": "npm run build",
4040
"prepublishOnly": "npm run compile && np --yolo --no-publish",
4141
"postpublish": "tnpm sync rc-menu",
4242
"start": "dumi dev",
43-
"test": "father test"
43+
"test": "rc-test"
4444
},
4545
"dependencies": {
4646
"@babel/runtime": "^7.10.1",
@@ -61,15 +61,16 @@
6161
"cross-env": "^7.0.0",
6262
"dumi": "^1.1.0",
6363
"eslint": "^7.0.0",
64-
"father": "^2.22.0",
65-
"father-build": "^1.18.6",
64+
"father": "^4.0.0",
6665
"gh-pages": "^3.1.0",
6766
"less": "^3.10.3",
6867
"np": "^6.0.0",
68+
"rc-test": "^7.0.14",
6969
"react": "^18.0.0",
7070
"react-dom": "^18.0.0",
7171
"regenerator-runtime": "^0.13.7",
72-
"typescript": "^4.0.5"
72+
"typescript": "^4.0.5",
73+
"@rc-component/father-plugin": "^1.0.0"
7374
},
7475
"peerDependencies": {
7576
"react": ">=16.9.0",

tsconfig.json

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,20 @@
33
"target": "esnext",
44
"moduleResolution": "node",
55
"baseUrl": "./",
6-
"jsx": "preserve",
6+
"jsx": "react",
77
"declaration": true,
88
"skipLibCheck": true,
99
"esModuleInterop": true,
1010
"paths": {
11-
"@/*": ["src/*"],
12-
"@@/*": ["src/.umi/*"],
13-
"rc-menu": ["src/index.tsx"]
11+
"@/*": [
12+
"src/*"
13+
],
14+
"@@/*": [
15+
"src/.umi/*"
16+
],
17+
"rc-menu": [
18+
"src/index.tsx"
19+
]
1420
}
1521
}
16-
}
22+
}

0 commit comments

Comments
 (0)