refactor: upgrade to vite5

This commit is contained in:
axolotle 2024-03-04 16:44:05 +01:00
parent d398b93c6a
commit 4ff3c33b78
2 changed files with 7 additions and 2 deletions

View file

@ -39,7 +39,7 @@
"portal-vue": "^2.1.7",
"prettier": "^3.2.5",
"sass": "^1.60.0",
"vite": "^4.2.1"
"vite": "^5.1.4"
},
"browserslist": [
"> 1%",

View file

@ -25,7 +25,12 @@ export default defineConfig(({ command, mode }) => {
alias: [
{ find: 'vue', replacement: '@vue/compat' },
// this is required for the SCSS modules imports with `~` (node_modules)
{ find: /^~(.*)$/, replacement: '$1' },
{
find: /^~(.*)$/,
replacement: fileURLToPath(
new URL('./node_modules/$1', import.meta.url),
),
},
{
find: '@',
replacement: fileURLToPath(new URL('./src', import.meta.url)),