我正在尝试理解反应导航,我正在设置一个概念应用程序来理解.
我最初在努力的是,我得到错误信息"路由的组件"SomeRoute"必须是一个React组件"
我知道,这意味着什么,但我不明白为什么会抛出这个错误.
我有以下设置:
App.js:
import React from 'react';
import { Root } from './config/router';
import { SafeArea } from 'react-native';
class App extends Component {
render() {
return <Root />;
}
}
export default App;
Run Code Online (Sandbox Code Playgroud)
router.js(config/router.js)
import React from 'react';
import { DrawerNavigator, TabNavigator, StackNavigator } from 'react-navigation';
import Feed from './../components/Feed';
import Search from './../components/Search';
import Favorites from './../components/Favorites';
import TextList from './../components/ComingSoon';
import Detail from './../components/Detail';
import Downloads from './../components/Downloads';
export const FeedStack = StackNavigator({
Feed: { …Run Code Online (Sandbox Code Playgroud) 我最近升级了 react-native 版本
react-native upgrade
Run Code Online (Sandbox Code Playgroud)
并遵循所有步骤,到目前为止没有任何错误。现在,当我想构建 ios 版本时,出现以下错误:
? ld: symbol(s) not found for architecture x86_64
? clang: error: linker command failed with exit code 1 (use -v to see invocation)
Run Code Online (Sandbox Code Playgroud)
** 构建失败 **
以下构建命令失败:
Ld build/Build/Products/Debug-iphonesimulator/CustomName.app/CustomName normal x86_64
Run Code Online (Sandbox Code Playgroud)
(1 次失败)
The following commands produced analyzer issues:
Analyze Base/RCTModuleMethod.mm normal x86_64
Analyze RCTNetInfo.m normal x86_64
Analyze RCTImageCache.m normal x86_64
(3 commands with analyzer issues)
Run Code Online (Sandbox Code Playgroud)
我的项目环境
React Native Environment Info:
System:
OS: macOS 10.14.3
CPU: (8) x64 Intel(R) Core(TM) i7-7700HQ CPU …