breact
Browser react utility
Last updated 2 years ago by okunishinishi .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install breact 
SYNC missed versions from official npm registry.

breact

Build Status npm Version JS Standard

Browser react utility

Installation

$ npm install breact --save

Usage

'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

Current Tags

  • 1.3.0                                ...           latest (2 years ago)

18 Versions

  • 1.3.0                                ...           2 years ago
  • 1.2.1                                ...           2 years ago
  • 1.2.0                                ...           2 years ago
  • 1.1.5                                ...           2 years ago
  • 1.1.4                                ...           2 years ago
  • 1.1.3                                ...           2 years ago
  • 1.1.2                                ...           2 years ago
  • 1.1.1                                ...           2 years ago
  • 1.1.0                                ...           2 years ago
  • 1.0.8                                ...           2 years ago
  • 1.0.7                                ...           2 years ago
  • 1.0.6                                ...           2 years ago
  • 1.0.5                                ...           2 years ago
  • 1.0.4                                ...           2 years ago
  • 1.0.3                                ...           2 years ago
  • 1.0.2                                ...           2 years ago
  • 1.0.1                                ...           2 years ago
  • 1.0.0                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 39
Last Day 0
Last Week 25
Last Month 54
Dependencies (4)
Dev Dependencies (15)

Copyright 2014 - 2016 © taobao.org |