midou36o.github.io/vite.config.ts

26 lines
581 B
TypeScript
Raw Normal View History

2023-01-19 18:05:09 +01:00
import { sveltekit } from '@sveltejs/kit/vite';
import type { UserConfig } from 'vite';
2023-12-29 16:14:25 +01:00
//import { defineConfig } from 'vite';
2023-01-19 18:05:09 +01:00
import UnoCSS from 'unocss/vite';
2023-12-29 16:14:25 +01:00
//import presetIcons from '@unocss/preset-icons';
//import presetWebFonts from '@unocss/preset-web-fonts';
2023-01-19 18:05:09 +01:00
const config: UserConfig = {
2023-12-29 16:14:25 +01:00
plugins: [
sveltekit(),
UnoCSS()
/* Self note: Don't add a config between the (), it just overrides the external config. */
2023-12-29 16:14:25 +01:00
],
optimizeDeps: {
2023-12-29 16:14:25 +01:00
include: ['dayjs/plugin/relativeTime.js']
},
server: {
port: 3000
},
preview: {
port: 3020
2023-12-29 16:14:25 +01:00
}
2023-01-19 18:05:09 +01:00
};
export default config;