Skip to content

Commit ce7cf25

Browse files
committed
chore(button-component): update vite to v7
- `@vitejs/plugin-react` added support for `vite@v7` since `v4.5.2`. - required adding `react` as peer dependency of `@lib/components` to prevent resolve import errors of `react/jsx-runtime` on `build` - `typescript` to `v5.5+` due to changes of `@vitejs/plugin-react` in `v5.0.0` - similar issue: vitejs/vite-plugin-react#985 - change: vitejs/vite-plugin-react@b9efa3f#diff-d1f942b9a74f586a80bca3733150b7c692a6460e8350bc19cbbad1d53f95b356 - `sass` to `1.70.0+` due to changes in peer deps of `vite@v6.3.10` - pr: vitejs/vite#19979 - `@use` rule instead of `@import`. `@import` is deprecated since `v1.80.0`
1 parent 537d04c commit ce7cf25

File tree

6 files changed

+569
-43
lines changed

6 files changed

+569
-43
lines changed

TODO.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,14 @@
1414
- `todo-app`
1515
- `windbnb`
1616

17-
`pnpm` version is set in `packageManager` or root `package.json` and
17+
`pnpm` version is set in `packageManager` of root `package.json` and
1818
`node` version is set in root `.nvmrc`.
1919

20-
## Vite
20+
- update `tsconfig.*.json` files to match [create-vite@8.2.0][create-vite@8.2.0]
21+
- update `eslint` to `v9` and config files to match [create-vite@8.2.0][create-vite@8.2.0]
22+
- update `vite` to `v7`:
23+
- update `@vitejs/plugin-react` to support `vite@v7`
24+
- update `astro` and related packages to support `vite@v7`
25+
- migrate content-only apps to `astro`. pre-render content to static HTML.
2126

22-
### Update to `v7`
23-
24-
### Legacy
25-
26-
- update `@vitejs/plugin-react` to support `vite@v7`
27-
- update `astro` and related packages to support `vite@v7`
27+
[create-vite@8.2.0]: https://github.com/vitejs/vite/tree/create-vite%408.2.0/packages/create-vite/template-react-ts
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
@import "button.scss";
2-
@import "button-outline.scss";
3-
@import "button-text.scss";
1+
@use "button.scss";
2+
@use "button-outline.scss";
3+
@use "button-text.scss";
44

5-
@import "sizes.scss";
6-
@import "colors.scss";
5+
@use "sizes.scss";
6+
@use "colors.scss";

legacy/button-component/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@
2727
},
2828
"devDependencies": {
2929
"@hrc/type-utils": "catalog:",
30-
"@vitejs/plugin-react": "catalog:",
31-
"sass": "catalog:",
32-
"typescript": "catalog:",
33-
"vite": "catalog:"
30+
"@vitejs/plugin-react": "catalog:vite7",
31+
"sass": "catalog:vite7",
32+
"typescript": "catalog:vite7",
33+
"vite": "catalog:vite7"
3434
},
3535
"engines": {
3636
"node": ">=18",

libs/components/package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,8 @@
88
"@hrc/material-icons": "catalog:",
99
"@hrc/toggle-theme": "catalog:",
1010
"@lib/sass-utils": "workspace:*"
11+
},
12+
"peerDependencies": {
13+
"react": "catalog:"
1114
}
1215
}

0 commit comments

Comments
 (0)