gulp-reacss
Gulp plugin for adding styles from a css files to the component
Last updated 5 years ago by yodairish .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install gulp-reacss 
SYNC missed versions from official npm registry.

gulp-reacss Build Status

Adding styles from a css files to the react component. Using templates where you set list of selectors and css files separated by comma.

Css files parsed by css

Install

$ npm install gulp-reacss --save-dev

Usage

// component.js
var styles = @('.some',
               '.some .one'
                =>
                'css/comp.css',
                'css/all.css')
var Component = React.createClass({
  render: function(){
    return (
      <div className="one" style={styles}></div>
    );
  }
});
// gulpfile.js
var gulp = require('gulp');
var reacss = require('gulp-reacss');

gulp.task('reacss', function () {
	return gulp.src('component.js')
		.pipe(reacss())
		.pipe(gulp.dest('dist'));
});

License

MIT © Yodairish 2014

Current Tags

  • 0.0.1                                ...           latest (5 years ago)

1 Versions

  • 0.0.1                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 2
Dependencies (4)
Dev Dependencies (2)
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |