This package has been deprecated

Author message:

This package is deprecated. Please use reBEM: github.com/rebem

bemreact

0.7.0 • Public • Published

bemreact

npm travis climate gratipay

Convert bemjson into React elements. Work in progress.

Install

$ npm i -S bemreact

Usage

var BemReact = require('bemreact');
 
var Button = BemReact.createClass({
    render: function() {
        return {
            block: 'button',
            tag: 'button',
            mods: {
                size: this.props.size,
                disabled: this.props.disabled
            },
            props: {
                disabled: this.props.disabled
            },
            content: [
                {
                    elem: 'icon',
                    mods: {
                        type: 'button'
                    }
                }, {
                    elem: 'text',
                    content: 'ololo'
                }
            ]
        }
    }
});

License

WTFPL

/bemreact/

    Package Sidebar

    Install

    npm i bemreact

    Weekly Downloads

    1

    Version

    0.7.0

    License

    WTFPL

    Last publish

    Collaborators

    • deepsweet