@weflex/weflex-ui

2.8.4 • Public • Published

weflex-ui

NPM version Build status Dependency Status Test coverage Downloads

The UI Library that used by WeFlex Products and Developers.

Get Started

import UIFramework from 'weflex-ui';

class ExampleForm extends React.Component {
  constructor(props) {
    super(props);
    this.state = {
      username: null,
      password: null,
    };
  }
  onLogin() {
    // this.state.username
    // this.state.password
  }
  render() {
    return (
      <UIFramework>
        <UIFramework.Row name="username">
          <UIFramework.TextInput bindStateCtx={this} bindStateName="username" />
        </UIFramework.Row>
        <UIFramework.Row name="username">
          <UITextInput bindStateCtx={this} bindStateName="username" password={true} />
        </UIFramework.Row>
        <UIFramework.Row name="username">
          <UIFramework.Button text="login" onClick={this.onLogin.bind(this)} />
        </UIFramework.Row>
      </UIFramework>
    )
  }
}

Components

See src/ for components.

Installation

$ npm install weflex-ui --save-dev

Tests

$ npm install
$ npm test

Example

$ cd examples
$ npm install && npm start
http://localhost:6798/

License

MIT @ WeFlex

Readme

Keywords

Package Sidebar

Install

npm i @weflex/weflex-ui

Weekly Downloads

0

Version

2.8.4

License

MIT

Last publish

Collaborators

  • pbalan
  • suqin