2.1.0 • Published 10 months ago

@zzwy/wy-injectfile v2.1.0

Weekly downloads
-
License
ISC
Repository
-
Last release
10 months ago

wy-injectfile

vite抽离公共资源,引用外部链接文件

Installation

npm i @zzwy/wy-injectfile

Import

vite.config.js内导入

import injectFiles from "@zzwy/vite-injectfile";

export default defineConfig({
  plugins: [
	 vue(),
	 injectFiles()
  ]
})

Using

1、字段使用方法

{
	path: url + 'xxx.css',//文件路径
	injectAll:true,//不区分开发环境
},
{
	name: 'vue',//名称,单独引用的文件不需要
	global: 'Vue',//全局,单独引用的文件不需要
	path: 'xxxx/vue3.2.30.js',//文件路径

},
2.0.3

10 months ago

2.1.0

10 months ago

2.0.2

1 year ago

2.0.1

1 year ago

2.0.0

1 year ago

1.0.1

3 years ago

1.0.0

3 years ago