0.0.3 • Published 2 years ago

vite-plugin-file-create v0.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

vite-plugin-file-create

一个vite插件, 在vite打包时创建文件并保存至输出目录.

安装

npm i -D vite-plugin-file-create # yarn add -D vite-plugin-file-create

使用

下面是一个示例:生成版本号文件并保存到输出目录。

// vite.config.js / vite.config.ts
import { viteFileCreate } from 'vite-plugin-file-create'

const versionStr = `V1.0.1.${Date.now()}` // 版本号

export default {
  plugins: [
    viteFileCreate(versionStr, "version.txt")
  ]
}
0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago