autojs-ui-loader

1.0.3 • Public • Published

可以使 webpack 打包 autojs UI

安装

npm i autojs-ui-loader --dev

使用

  1. 在 loader 加上。( 推荐使用 jsx 或 tsx 编写 autojs UI )
{
	test: /\.tsx?$/,
	use: 'autojs-ui-loader',
	exclude: /node_modules/,
}
  1. 在 plugins 加上
const { AutoUIPlugin } = require('autojs-ui-loader')
...
plugins: [
	new AutoUIPlugin({
		buildPath: path.join(__dirname, 'dist'),
		fileFlag: 'bundle.js',
	})
]
  1. 参数说明
  • buildPath: string, 打包后的文件夹路径
  • fileFlag: string | 正则 RegExp, UI 打包的文件特征, 用于区别其它文件

例子

您可以在 autojs-typescript-template 作为参考。

Readme

Keywords

Package Sidebar

Install

npm i autojs-ui-loader

Weekly Downloads

6

Version

1.0.3

License

ISC

Unpacked Size

2.64 kB

Total Files

3

Last publish

Collaborators

  • ludongmin