Skip to content

Commit

Permalink
chore: bump father@4 (#532)
Browse files Browse the repository at this point in the history
* chore: bump father@4

* chore: code clean

* chore: update test case
  • Loading branch information
MadCcc authored Oct 26, 2023
1 parent f68f8a7 commit a885647
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 23 deletions.
14 changes: 5 additions & 9 deletions .fatherrc.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
export default {
cjs: 'babel',
esm: { type: 'babel', importLibToEs: true },
preCommit: {
eslint: true,
prettier: true,
},
runtimeHelpers: true,
};
import { defineConfig } from 'father';

export default defineConfig({
plugins: ['@rc-component/father-plugin'],
});
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

- uses: actions/setup-node@v1
with:
node-version: '12'
node-version: '18'

- name: cache package-lock.json
uses: actions/cache@v2
Expand All @@ -24,7 +24,7 @@ jobs:
key: lock-${{ github.sha }}

- name: create package-lock.json
run: npm i --package-lock-only
run: npm i --package-lock-only --ignore-scripts

- name: hack for singe file
run: |
Expand Down
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npx lint-staged
26 changes: 17 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,18 @@
"prepublishOnly": "npm run compile && np --yolo --no-publish && npm run gh-pages",
"lint": "eslint src/ --ext .ts,.tsx,.jsx,.js,.md",
"prettier": "prettier --write \"**/*.{ts,tsx,js,jsx,json,md}\"",
"pretty-quick": "pretty-quick",
"test": "father test",
"coverage": "father test --coverage",
"now-build": "npm run docs:build"
"test": "rc-test",
"coverage": "rc-test --coverage",
"now-build": "npm run docs:build",
"prepare": "husky install"
},
"dependencies": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.1",
"rc-util": "^5.32.2"
},
"devDependencies": {
"@rc-component/father-plugin": "^1.0.0",
"@types/classnames": "^2.2.9",
"@types/jest": "^29.2.2",
"@types/keyv": "^3.1.4",
Expand All @@ -59,20 +60,21 @@
"cross-env": "^7.0.0",
"dumi": "^2.1.2",
"enzyme": "^3.0.0",
"enzyme-adapter-react-16": "^1.0.1",
"enzyme-adapter-react-16": "^1.15.6",
"enzyme-to-json": "^3.4.0",
"eslint": "^7.0.0",
"father": "^2.13.4",
"father": "^4.0.0",
"gh-pages": "^4.0.0",
"glob": "^7.1.6",
"husky": "^8.0.3",
"less": "^3.10.3",
"lint-staged": "^15.0.2",
"np": "^7.0.0",
"prettier": "^2.0.1",
"pretty-quick": "^3.0.0",
"rc-select": "^14.1.2",
"rc-test": "^7.0.15",
"react": "^16.0.0",
"react-dom": "^16.0.0",
"react-test-renderer": "^16.0.0"
"react-dom": "^16.0.0"
},
"peerDependencies": {
"react": ">=16.9.0",
Expand All @@ -83,5 +85,11 @@
},
"tnpm": {
"mode": "npm"
},
"lint-staged": {
"**/*.{js,jsx,tsx,ts,md,json}": [
"prettier --write",
"git add"
]
}
}
4 changes: 2 additions & 2 deletions tests/two-pagination.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import 'rc-select/assets/index.less';
import React from 'react';
// import 'rc-select/assets/index.less';
import Select from 'rc-select';
import React from 'react';
import Pagination from '../src';

class Hello extends React.Component {
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"target": "esnext",
"moduleResolution": "node",
"baseUrl": "./",
"jsx": "preserve",
"jsx": "react",
"declaration": true,
"skipLibCheck": true,
"esModuleInterop": true,
Expand Down

0 comments on commit a885647

Please sign in to comment.