Skip to main content

Output Options

These options configure the build output generated by chayns-toolkit build.

All options aswell as the toolkit.config.js file itself are optional.

/toolkit.config.js
module.exports = {    output: {        /**         * Toggles single-file build functionality. Read more below         *         * @type {boolean}         */        singleBundle: false,
        /**         * Change the file-name your of primary output bundle. You can use any         * of the [webpack substitutions](https://webpack.js.org/configuration/output/#template-strings)         * as well as the `[package]` substitution, which will be replaced by         * the package name specified in your `package.json`. Defaults to         * `[package].[contenthash].js`.         *         * @type {string}         */        filename: "[package].[contenthash].js",
        /**         * Set an absolute path where your output will be emitted to.         *         * @type {string}         */        path: "//my-qa-server/example-project",    },    // ... other options ...}

Single File Builds#

In single-file build mode, the compiler will inline all assets (CSS, images, etc.) together with all JavaScript into a single bundle. This can be useful when building smaller fragments of a UI, e.g. some kind of plugin.