Skip to content

Commit

Permalink
feat: upgrade and support react 19
Browse files Browse the repository at this point in the history
BREAKING CHANGE
  • Loading branch information
thebuilder committed Dec 14, 2024
1 parent 3b2e0ea commit 9061bf4
Show file tree
Hide file tree
Showing 7 changed files with 2,336 additions and 4,667 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,10 @@ jobs:
fail-fast: false
matrix:
react:
- 16
- 17
- 18
- 19
- latest
- rc
steps:
- run: corepack enable
- uses: actions/checkout@v4
Expand All @@ -49,10 +48,9 @@ jobs:
- name: Install dependencies
run: pnpm install
- name: Install legacy testing-library
if: ${{ startsWith(matrix.react, '16') || startsWith(matrix.react, '17') }}
if: ${{ startsWith(matrix.react, '17') }}
run: pnpm add -D @testing-library/react@12.1.4
- name: Install legacy React types
if: ${{ startsWith(matrix.react, '16') || startsWith(matrix.react, '17') || startsWith(matrix.react, '18') }}
- name: Install React types
run: pnpm add -D @types/react@${{ matrix.react }} @types/react-dom@${{ matrix.react }}
- name: Install ${{ matrix.react }}
run: pnpm add -D react@${{ matrix.react }} react-dom@${{ matrix.react }}
Expand Down
46 changes: 20 additions & 26 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -107,45 +107,39 @@
}
],
"peerDependencies": {
"react": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
"react-dom": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0"
"react": "^17.0.0 || ^18.0.0 || ^19.0.0",
"react-dom": "^17.0.0 || ^18.0.0 || ^19.0.0"
},
"devDependencies": {
"@arethetypeswrong/cli": "^0.15.3",
"@arethetypeswrong/cli": "^0.17.1",
"@biomejs/biome": "^1.9.4",
"@size-limit/preset-small-lib": "^11.1.4",
"@testing-library/jest-dom": "^6.4.6",
"@testing-library/react": "^16.0.0",
"@types/react": "^18.3.3",
"@types/react-dom": "^18.3.1",
"@vitejs/plugin-react": "^4.3.1",
"@vitest/browser": "^2.1.4",
"@vitest/coverage-istanbul": "^2.1.4",
"lint-staged": "^15.2.7",
"@size-limit/preset-small-lib": "^11.1.6",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^16.1.0",
"@types/react": "^19.0.1",
"@types/react-dom": "^19.0.2",
"@vitejs/plugin-react": "^4.3.4",
"@vitest/browser": "^2.1.8",
"@vitest/coverage-istanbul": "^2.1.8",
"lint-staged": "^15.2.11",
"microbundle": "^0.15.1",
"npm-run-all": "^4.1.5",
"playwright": "^1.45.1",
"publint": "^0.2.8",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"playwright": "^1.49.1",
"publint": "^0.2.12",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"simple-git-hooks": "^2.11.1",
"size-limit": "^11.1.4",
"tsup": "^8.1.0",
"typescript": "^5.5.3",
"vitest": "^2.1.4"
"size-limit": "^11.1.6",
"tsup": "^8.3.5",
"typescript": "^5.7.2",
"vitest": "^2.1.8"
},
"peerDependenciesMeta": {
"react-dom": {
"optional": true
}
},
"pnpm": {
"peerDependencyRules": {
"allowedVersions": {
"react": "18",
"vite": "5"
}
},
"allowedDeprecatedVersions": {
"rollup-plugin-terser": "*",
"sourcemap-codec": "*",
Expand Down
Loading

0 comments on commit 9061bf4

Please sign in to comment.