人。
我m work on RN app.
In the dev process everything work fine, the app launched at my device, but when i tried generate APK, i
会遇到下一条错误消息:
SyntaxError D:/Sites/work/CECI/src/stores/AppStore.js:意外 令牌(12:4)
:app:bundleReleaseJsAndAssets FAILED
建立失败
总时间:43.156秒
失败:构建因异常而失败。
出了什么问题:任务执行失败':app:bundleReleaseJsAndAssets'。
处理'命令'cmd''以非零退出值1
结束尝试:使用--stacktrace选项运行以获取堆栈跟踪。使用--info或--debug选项运行以获得更多日志输出。
使用退出代码1完成处理
AppStore.js的开头:
import {action, computed, observable, toJS} from 'mobx';
import {forEach, size, flatMap, sortBy, last} from 'lodash';
import firebase from 'react-native-firebase';
import store from 'rn-object-store';
import moment from 'moment';
const auth = firebase.auth();
const db = firebase.firestore();
class AppStore {
@observable user = null;
@observable auth = {
authUser: null,
authError: null,
loggedIn: null
};
@observable userRef = null;
@observable decisionsRef = null;
@observable quizzesRef = null;
@observable _decisions = {};
@observable _quizzes = {};
@observable activeQuestion = 0;
@observable activeQuiz = null;
@observable activeDecision = null;
@observable reports = {};
因此,如果我理解右行有问题是@observable user = null;
可能有什么问题?
答案 0 :(得分:0)
尝试cd android&& ./gradlew clean