Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/edd/broccoli-react

Broccoli preprocessor for React JSX
https://github.com/edd/broccoli-react

Last synced: 2 months ago
JSON representation

Broccoli preprocessor for React JSX

Awesome Lists containing this project

README

        

# [broccoli](https://github.com/joliss/broccoli)-[react](https://github.com/facebook/react) [![Build Status](https://travis-ci.org/eddhannay/broccoli-react.png?branch=master)](https://travis-ci.org/eddhannay/broccoli-react)

A [React JSX](https://github.com/facebook/react) filter for [broccoli](https://github.com/joliss/broccoli).

## Installation

```bash
npm install --save broccoli-react
```
## Usage

```js
var filterReact = require('broccoli-react');
tree = filterReact(tree);
```

## Options

### extensions
Type: `Array`
Default: `['jsx']`

Specify the extensions for the source files.

### babelOptions
Type: `Object`
Default: `{}`

Specify options for babel, useful for e.g. plugins, transforms etc.

```js
tree = filterReact(tree, {
extensions: ['js'],
babelOptions: { plugins: ["transform-class-properties"] }
});
```