1.3.0 • Published 9 years ago
breact v1.3.0
breact
Browser react utility
Installation
$ npm install breact --saveUsage
'use strict'
import {mount, create, once} from 'breact'
import IndexComponent from '../components/index_component'
once('DOMContentLoaded', () => {
let element = create(IndexComponent, {})
mount('mount-root', element).then(() => {
// The component is ready.
})
})Functions
Available functions
| Signature | Description |
|---|---|
autobind(context) -> | Auto bind methods |
create(Component, props, children) -> Object | Create an element |
markup(Component, props, children) -> string | Create static markup |
mount(container, element) -> Promise | Mount an element into dom |
once(event, handler) | Bind window event once |
wrap(Base, spec) -> Object | Wrap a element with higher order component |
License
This software is released under the MIT License.
Links
1.3.0
9 years ago
1.2.1
9 years ago
1.2.0
10 years ago
1.1.5
10 years ago
1.1.4
10 years ago
1.1.3
10 years ago
1.1.2
10 years ago
1.1.1
10 years ago
1.1.0
10 years ago
1.0.8
10 years ago
1.0.7
10 years ago
1.0.6
10 years ago
1.0.5
10 years ago
1.0.4
10 years ago
1.0.3
10 years ago
1.0.2
10 years ago
1.0.1
10 years ago
1.0.0
10 years ago