You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
644 B
29 lines
644 B
|
6 days ago
|
import { defineConfig } from 'vite'
|
||
|
|
import uni from '@dcloudio/vite-plugin-uni'
|
||
|
|
import { resolve } from 'path'
|
||
|
|
// https://vitejs.dev/config/
|
||
|
|
export default defineConfig(async () => {
|
||
|
|
const UnoCss = await import('unocss/vite').then(i => i.default)
|
||
|
|
|
||
|
|
return {
|
||
|
|
plugins: [
|
||
|
|
uni(),
|
||
|
|
// https://github.com/unocss/unocss
|
||
|
|
UnoCss()
|
||
|
|
],
|
||
|
|
css: {
|
||
|
|
preprocessorOptions: {
|
||
|
|
scss: {
|
||
|
|
// 取消sass废弃API的报警
|
||
|
|
silenceDeprecations: ['legacy-js-api', 'color-functions', 'import']
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
resolve: {
|
||
|
|
alias: {
|
||
|
|
'@': resolve(__dirname, 'src')
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
})
|