5.0.2 • Published 7 years ago

babel-plugin-transform-dwayne-js v5.0.2

Weekly downloads
30
License
-
Repository
-
Last release
7 years ago

babel-plugin-transform-dwayne-js

Babel plugin for transforming js tagged expression into functions.

It's recommended to use babel-preset-dwayne instead of the plugin itself.

Example

Input:

const expression = js`a + b`;

Output:

const expression = _ => _.a + _.b;

Options

This plugin accepts only one option: taggedJsFuncName - name of the tag function. The default value is js.

Transformer

It's similar to transform-dwayne-js, but for babel and js expressions only.

All the options passed to the plugin are passed to the transformer itself.

By default the plugin sets options.useES6 to true.