babel-plugin-actions

1.0.2 • Public • Published

babel-plugin-actions

Babel plugin to generate traceable type for the-actions.

Issues related to the-actions should be reporter on the-actions issue-tracker.

Install

npm install --save-dev babel-plugin-actions

Usage

Run:

babel --plugins actions script.js

Or add the plugin to your .babelrc configuration:

{
  "plugins": [ "actions" ]
}

Example

The plugin will compile the following code:

// actions.js
const UserAction = ActionCreator();
const OtherActions = {
    Example: ActionCreator()
}

into:

// actions.js
const UserAction = ActionCreator("actions.js: UserAction");
const OtherActions = {
    Example: ActionCreator("actions.js: OtherActions.Example")
}

Package Sidebar

Install

npm i babel-plugin-actions

Weekly Downloads

4

Version

1.0.2

License

MIT

Unpacked Size

4 kB

Total Files

5

Last publish

Collaborators

  • fightingcat