adobe/react-twist-webpack-plugin

Name: react-twist-webpack-plugin

Owner: Adobe Systems Incorporated

Description: Webpack plugin for React-Twist

Created: 2017-12-22 02:06:19.0

Updated: 2018-01-22 18:51:47.0

Pushed: 2018-02-05 19:09:29.0

Homepage: null

Size: 194

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Webpack Plugin for React-Twist

Build Status

This library contains a Webpack plugin for building an application with React-Twist.

Getting Started

If you want to use both the state-management and component layers of Twist, you'll need to install the following (via NPM or Yarn):

If you're not using webpack, you can also get hold of the Babel configuration directly, using @twist/configuration (this is done automatically by the webpack plugin).

After that, the only thing you need is a .twistrc file in the root of your project, that tells Twist which libraries to include (this is also used by the Twist ESlint plugin). There are a number of advanced options, but to get up and running, you just need to tell Twist that you're using React-Twist:


"libraries": [
    "@twist/react"
]

In your webpack.conf.js you can now include the React Twist plugin - by default this will compile all files that end in .jsx with Twist and React:

t ReactTwistPlugin = require('@twist/react-webpack-plugin');

le.exports = {
...
plugins: [
    new ReactTwistPlugin(),
    ...
],
...


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.