Skip to content

Commit

Permalink
chore: fix vite.config for v3
Browse files Browse the repository at this point in the history
  • Loading branch information
MR-Mostafa committed Aug 15, 2022
1 parent 4a03bc0 commit 862aefa
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const shouldAnalyze = process.env.ANALYZE ?? false;
const isHttps = process.env.HTTPS ?? false;

// https://vitejs.dev/config/
export default defineConfig((mode) => {
export default defineConfig((config: ConfigEnv) => {
return {
plugins: [
react({
Expand All @@ -40,13 +40,12 @@ export default defineConfig((mode) => {
Unocss(),

viteImagemin({
disable: mode === 'development',
disable: config.mode === 'development',
mozjpeg: {
progressive: true,
quality: 80,
},
optipng: {
enabled: true,
optimizationLevel: 3,
},
pngquant: {
Expand Down

0 comments on commit 862aefa

Please sign in to comment.