P粉2324090692023-08-28 00:38:32
Try this
1. If you want Vite to use a file named my.config.js instead of the default vite.config.js
Your my.config.js file is located in the root directory of your project.
2. Open a terminal or command prompt and navigate to the root directory of your project.
3. Use the --config flagRun the vite build command to specify the path to the custom configuration file.
vite build --config my.config.js
4. This command tells Vite to use my.config.js as the configuration file for the build process
You can provide custom configuration files to Vite and override the default behavior using vite.config.js.