G. *_*ide 1 javascript babeljs react-native
我今天早上将我的项目从RN 0.15.0升级到0.16.0,由于传递给Babel 6而出现了很多错误.有一个我不知道的(我猜我的.babelrc文件中缺少了它)
此代码在升级之前工作正常:
'use strict';
import alt from '../alt';
import MeStore from '../stores/Me';
export class MeActions {
showedCurrentPosition(showed) {
this.dispatch(showed);
}
}
export default alt.createActions(MeActions);
Run Code Online (Sandbox Code Playgroud)
这是我使用插件alt的Alt.js文件:
'use strict';
import Alt from 'alt';
export default new Alt();
Run Code Online (Sandbox Code Playgroud)
现在,我在调用时运行代码"this.dispatch不是函数" MeActions.showedCurrentPosition(true);
| 归档时间: |
|
| 查看次数: |
1606 次 |
| 最近记录: |