Skip to content

CcSimple/vite-copy-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vite-copy-plugin

试了几个资源复制插件,不是没用就是不合适,于是便有了此插件

安装

npm i vite-copy-plugin

使用

import CopyPlugin from "vite-copy-plugin";

// vite 配置
export default defineConfig({
  plugins: [
    CopyPlugin([
      // 目录复制
      {from: 'src/static', to: 'dist/static'},
      // 文件复制到目录(空及取vite配置的build.outDir 默认 dist)
      {from: 'src/static/style.css', to: ''}, 
      // 文件复制文件
      {from: 'src/static/style.css', to: 'dist/index.css'}, 
    ])
  ],
});

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published