0.1.3 • Published 6 years ago

hele-create-class v0.1.3

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

hele-create-class

A component class creator for hele.

Usage

// Use as an es module:
import { createClass } from "hele-create-class";
// Or use as a umd module:
const createClass = HEle.createClass;
// The method returns a component class:
const MyButton = createClass({
    // Pass your methods to it:
    render() {
        // ...
    },
    // Methods are automatically bound to the component instance:
    handleClick() {
        // ...
    },
    // `defaultProps` is also supported:
    defaultProps: {
        // ...
    }
});

Changelog

See CHANGELOG.md.