@flybywiresim/rollup-plugin-msfs

0.3.1 • Public • Published

Discord

GitHub latest release version Github All Releases download count GitHub contributors

About

Rollup plugin for bundling Microsoft Flight Simulator HTML instruments

Configuration

{
    name: string,                                       // Name of instrument (must be globally unique to all addons)
    elementName: string,                                // Name of custom element
    outputDir: string,                                  // Output directory for instrument files
    config: { index: string, isInteractive: boolean },  // Instrument configuration
    instrumentDir?: string,                             // Name of instrument ouptut directory (sub-directory of `outputDir`). Defaults to `name`
    jsBundle?: string,                                  // Name of JS rollup bundle. Defaults to bundle.js
    cssBundle?: string                                  // Name of CSS rollup bundle. Defaults to bundle.css
    imports?: string[],                                 // List of HTML/JS imports to add to the template HTML file. Defaults to none 
}

Example usage

const template = require('@flybywiresim/rollup-plugin-msfs');

    // other plugins ...
    template({
        name: 'MFD',
        elementName: 'a380x-mfd-element',
        config,
        imports: ['/JS/dataStorage.js'],
        outputDir: `${__dirname}/../../A380X/html_ui/Pages/VCockpit/Instruments/A380X`,
    }),
}

Readme

Keywords

none

Package Sidebar

Install

npm i @flybywiresim/rollup-plugin-msfs

Weekly Downloads

13

Version

0.3.1

License

MIT

Unpacked Size

10.9 kB

Total Files

6

Last publish

Collaborators

  • snek
  • nistei
  • wpine215
  • zigtag