Skip to content

sandwich99/dva-react2

 
 

Repository files navigation

dva-react2

NPM version Build Status NPM downloads Dependencies

Unofficial React bindings for dva, with react-router4

Getting Started

安装

$ npm i dva-react2 --save

使用

参考示例

import dva from 'dva-react2';
import IndexPage from './routes/IndexPage';
import './index.css';

// 1. Initialize
const app = dva();

// 2. Plugins
// app.use({});

// 3. Model
app.model(require('./models/example'));

app.mount(IndexPage); // !!! 此处 api 与官方相比略有改动,将 Root 组件挂载到 dva 实例上。

// 5. Start
app.start('#root');

LICENSE

MIT

About

Unofficial React bindings for dva, with react-router4.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%