- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我完全按照 React-native 入门指南中描述的步骤进行了操作:
https://facebook.github.io/react-native/docs/getting-started.html
当我打开项目并构建它时,构建失败:
RCTAssert.h file not found' in MyProjectNameTests.m .
Requirements
OS X - This repo only contains the iOS (7+) implementation right now, and Xcode only runs on Mac.
Xcode 6.3 or higher is recommended.
Homebrew is the recommended way to install io.js, watchman, and flow.
Install io.js 1.0 or newer. io.js is the modern version of Node.
Install nvm with its setup instructions here. Then run
nvm install
, which installs the latest compatible version of io.js and sets up your terminal so that typing node runs io.js. With nvm you can install multiple versions of Node and io.js and easily switch between them.
iojs-v2 && nvm alias default iojs-v2New to npm?
brew install watchman
. We recommend installing watchman, otherwise you might hit a node file watching bug.
brew install flow
. If you want to use flow. We recommend periodically runningbrew update && brew upgrade
to keep your programs up-to-date.
Quick Start
npm install -g react-native-cli
react-native init AwesomeProjectIn the newly created folder AwesomeProject/
Open AwesomeProject. xcodeproj and hit run in Xcode. Open index.ios.js in your text editor of choice and edit some lines. Hit cmd+R in your iOS simulator to reload the app and see your change!
最佳答案
测试应用程序找不到 header ,因为它不在 header 搜索路径中。
在左侧文件列表中,点击左上角的“文件夹”图标,然后在左上角选择您的应用程序。在这种情况下,“AwesomeProject”。
在应用程序图标出现的右侧,按住以更改为 AwesomeProjectTests。
在右侧,单击“build设置”选项卡。
然后向下滚动到标题搜索路径并将“$(SRCROOT)/node_modules/react-native/React”更改为“$(SRCROOT)/../node_modules/react-native/React”。
该应用程序现在应该编译。
关于React-native Xcode 构建失败-> 'RCTAssert.h file not found',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32250172/
我完全按照 React-native 入门指南中描述的步骤进行了操作: https://facebook.github.io/react-native/docs/getting-started.htm
我是一名优秀的程序员,十分优秀!