BF3RM / VextPack

A webpack plugin to automatically build a vuic file for Venice Unleashed

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

VextPack

A webpack plugin to automatically build a vuic file for Venice Unleashed

Problem

Venice Unleashed uses a .vuic file to pack the WebUI of a mod. Developers can use the vuic compiler to generate this file. The problem however is that when you use something like Webpack you really only wanna run one build command and be done. This plugin does exactly that, it generates a .vuic file after the files are built.

Installation

With npm

npm install --save-dev vextpack

With yarn

yarn -D vextpack

Usage

When installing VextPack it will automatically download the latest vuicc.exe, so you don't have to download it. Using VextPack is simple, it is just a regular Webpack plugin and can be used as follows:

// webpack.config.js
const { VextPackPlugin } = require('vextpack');

module.exports = {
    // ...
    plugins: [
        new VextPackPlugin({
            // OPTIONAL: Specify the location where the ui.vuic should be placed, defaults to '../'
            outputPath: '../',

            // OPTIONAL: Make a hot reloadable ui build, this creates a proxy ui that remotely loads the real ui
            hotReloadSupport: process.env.NODE_ENV !== 'production'
        })
    ]
}

About

A webpack plugin to automatically build a vuic file for Venice Unleashed

License:MIT License


Languages

Language:TypeScript 61.8%Language:JavaScript 22.9%Language:HTML 15.3%