vite-config
/
1.7.1
vite-config 1.7.1
Install from the command line:
Learn more about npm packages
$ npm install @codeoscopic/vite-config@1.7.1
Install via package.json:
"@codeoscopic/vite-config": "1.7.1"
About this version
This package includes our vite-config custom config for React projects.
- Install the package:
npm install -D vite @vitejs/plugin-react @codeoscopic/vite-config
- Create a
vite.config.ts
file in your project root with:
import { defineConfig } from "vite";
import defaultOptions from "@codeoscopic/vite-config/dist/react";
export default defineConfig(defaultOptions);
If you want to use antd in your project, change the import for @codeoscopic/vite-config/dist/react-antd
and install the following dependencies:
npm install antd
npm install -D less less-loader antd