Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump vite to 5.4.14 #2312

Merged
merged 22 commits into from
Jan 30, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions apps/css-workshop/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,12 @@
"dev": "astro dev",
"start": "astro dev",
"build": "astro build",
"preview": "astro preview --host",
"preview": "npx -y serve dist --listen 3050 -L",
"clean": "rimraf dist && rimraf node_modules && rimraf .turbo",
"approve": "backstop --config=./backstop/backstop.cjs approve",
"test:only": "backstop --config=./backstop/backstop.cjs test --docker",
"test": "npm-run-all -p -r \"preview\" \"test:only {1}\" --"
"test:only:wait-for-preview": "npx -y wait-on http://localhost:3050 && pnpm run test:only",
"test": "npm-run-all -p -r \"preview\" \"test:only:wait-for-preview {1}\" --"
},
"prettier": "configs/prettier-astro-config.js"
}
2 changes: 1 addition & 1 deletion packages/itwinui-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
"react": "^18.0.0",
"react-dom": "^18.0.0",
"typescript": "5",
"vite": "~5.1.8",
"vite": "~5.4.14",
"vitest": "^1.2.1"
},
"peerDependencies": {
Expand Down
12 changes: 12 additions & 0 deletions packages/itwinui-react/src/styles.js/vite.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,18 @@ export default defineConfig({
},
},
plugins: [
// https://github.com/vitejs/vite/pull/16051#issuecomment-2076616816
{
name: 'css-module-side-effectful',
enforce: 'post',
transform(_, id) {
if (id.endsWith('.module.css')) {
return {
moduleSideEffects: 'no-treeshake',
};
}
},
},
{
name: 'copy-files-after-build',
closeBundle: async () => {
Expand Down
Loading