BEM-VDOM
BEM DSL for your virtual DOM.
Installing
npm install bem-vdom
If you want to use BEM-VDOM in browser, you should use it with Browserify or any other NPM- and CommonJS-compatible module bundler you prefer. Make sure your virtual-dom
package is at version 2.0.1 or higher.
Usage
var createElement = ; var BEM = ;var b = BEMb;var e = BEMe; var sampleBlock = ; var vdom = sampleBlock;documentbody;
The example above translates to the following DOM:
Some text, maybe. Arrays for children are optional