UIKit/vite.config.ts

25 lines
654 B
TypeScript
Raw Normal View History

2023-08-14 12:03:23 +00:00
import react from '@vitejs/plugin-react';
import { resolve } from "path";
import { defineConfig } from 'vite';
import dts from 'vite-plugin-dts';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react(), dts({ include: ["lib"] })],
build: {
lib: {
entry: resolve(__dirname, "lib/index.ts"),
formats: ["es"]
},
copyPublicDir: false,
rollupOptions: {
external: ["axios", "react", "react-dom", "zustand"],
// output: {
// globals: {
// react: "TODO"
// },
// },
},
}
});