broccoli-msx

1.0.5 • Public • Published

broccoli-msx

Broccoli plugin for precompiling Mithril msx views into js

Install

npm install --save-dev broccoli-msx

Example

var msx = require('broccoli-msx')
  , pickFiles = require('broccoli-static-compiler')
  , mergeTrees = require('broccoli-merge-trees')
  ;

var js = pickFiles('src/js', {
  srcDir: '/',
  destDir: 'js'
})
js = msx(js, {precompiled: false})

module.exports = mergeTrees([js])

.msx files are automatically renamed to .js

API

msx(tree, [options: {}])

Options

options - options accepted by msx.transform().

{ harmony: true|false } - enables/disables ES6 transforms supported by JSX Transformer. Default: false

{ precompile: true|false } - enables/disable default precompilation and always output m() calls. Default: true

/broccoli-msx/

    Package Sidebar

    Install

    npm i broccoli-msx

    Weekly Downloads

    1

    Version

    1.0.5

    License

    MIT

    Last publish

    Collaborators

    • sqram