index.js 433 Bytes
Newer Older
1
import dva from 'dva';
afc163's avatar
afc163 committed
2
import G2 from 'g2';
3 4 5 6 7 8
// import { browserHistory } from 'dva/router';
import 'moment/locale/zh-cn';
import models from './models';

import './index.less';

afc163's avatar
afc163 committed
9 10
G2.track(false);

11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
// 1. Initialize
const app = dva({
  // history: browserHistory,
});

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

// 3. Model
models.forEach((m) => {
  app.model(m);
});

// 4. Router
app.router(require('./router'));

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