lifeto-shop/vite.config.ts

41 lines
892 B
TypeScript
Raw Normal View History

2025-06-20 05:41:10 +00:00
// ignore the type error onthe next line
// @ts-ignore
import tailwindcss from '@tailwindcss/vite'
2024-08-05 21:08:21 +00:00
import react from '@vitejs/plugin-react'
2025-05-25 05:17:41 +00:00
import path from 'path'
2025-06-20 05:41:10 +00:00
import { defineConfig } from 'vite'
2022-06-26 23:01:10 +00:00
export default defineConfig({
2025-06-20 05:41:10 +00:00
plugins: [react(), tailwindcss()],
2025-05-25 05:17:41 +00:00
resolve: {
alias: {
'@': path.resolve(__dirname, './src'),
},
},
2022-07-01 01:27:18 +00:00
server: {
proxy: {
// with options
'/lifeto': {
2025-06-20 05:41:10 +00:00
target: 'https://beta.lifeto.co/',
2022-07-01 01:27:18 +00:00
changeOrigin: true,
2025-06-20 05:41:10 +00:00
rewrite: path => path.replace(/^\/lifeto/, ''),
2022-07-01 01:27:18 +00:00
},
2025-06-20 05:41:10 +00:00
},
},
2022-06-26 23:01:10 +00:00
})
2024-08-05 21:08:21 +00:00
// https://vitejs.dev/config/
//export default defineConfig({
// plugins: [vue()],
// server: {
// proxy: {
// // with options
// '/lifeto': {
// target: "https://beta.lifeto.co/",
// changeOrigin: true,
// rewrite: (path) => path.replace(/^\/lifeto/, ''),
// },
// }
// }
//})