【发布时间】:2019-09-29 06:57:38
【问题描述】:
await 外的函数:返回错误不能使用关键字 await 请帮帮我...
I18n.defaultLocale = 'tr'
await AsyncStorage.getItem('locale').then((value) => {
I18n.locale = value
}).done();
I18n.fallbacks = true;
I18n.translations = { en, tr };
const currentLocale = I18n.currentLocale();
export function strings(name, params = {}) {
return I18n.t(name, params);
};
export default I18n;
【问题讨论】:
标签: react-native async-await expo