问题标签 [react-native]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
3 回答
9185 浏览

react-native - React Native and require('http')

The node core shipped with React Native does not seem to include node core http. Is it possible to add it and use at all within React Native?

Many Thanks in Advance.

0 投票
3 回答
22042 浏览

reactjs - react-native:多色文本视图

我想渲染一行文本,其中一些单词以不同的颜色突出显示。

理想情况下,我会使用带有 react 的 span 标签来做到这一点。

想知道我如何对 react-native 做同样的事情?

0 投票
1 回答
7161 浏览

javascript - react native 中的常用 js 模块

是否可以通过 react-native 使用常见的 js 模块?用例是在 React 项目的移动版本和 Web 版本之间共享逻辑。

0 投票
1 回答
4240 浏览

javascript - How to build React Native App for iPhone?

On the iPhone simulator everything works fine. When building the App for the iPhone i get the error:

A bundleURL is required to create an RCTRootView

In the AppDelegate.m i uncomment the following line;

And downloaded the prebuild main.jsbundle to the iOS folder in the project root:

0 投票
1 回答
822 浏览

xcode - 带有 react-native 的 Xcode 模拟器需要很长时间

我现在在 2009 年中期的 MPB 上运行 Mavericks 和最新的 Xcode。创建 AwesomeProject 然后使用 Xcode 构建没有问题。一旦模拟器出现,问题就开始了。我看到由 React Native 提供支持的白色屏幕,然后在它消失后需要很长时间,最后 Packager 给了我以下输出:

紧随其后的是大红屏!

Xcode 还通知我它与模拟器断开连接。我在 Xcode 中看到的一个警告是:

“使用启动屏幕文件并针对 iOS 7.1 及更早版本的应用程序还需要在资产目录中包含启动图像。”

如何最终完成入门测试并体验 React Native?

0 投票
2 回答
6543 浏览

react-native - 如何使用 react-native 创建一个具有原生外观的模态视图 segue?

有没有办法执行模态搜索,从底部向上动画视图和导航栏,覆盖现有的导航栏、视图和标签栏等?

UIExplorer 中有一个类似的示例,其中视图“Navigator”使用“configureScene”通过 Navigator.SceneConfigs.FloatFromBottom 等从底部浮动视图(但不是导航栏)。本机应用程序模式 segues 应该为新导航栏设置动画,并且从底部向上查看。注意:健康应用就是一个很好的例子,点击“医疗 ID”选项卡,然后点击导航栏中的“编辑”按钮,注意它的导航栏和视图如何动画并覆盖现有的导航栏、标签栏和视图。

我可以在 facebook groups 应用程序中看到一个模态 segue,据我了解,这是 react-native。单击“组”选项卡,单击“创建”导航栏按钮。

有谁知道如何在 react-native 中实现原生模式 segues?

0 投票
6 回答
102888 浏览

react-native - react native是否支持base64编码的图像?

react native是否支持base 64编码的图像?

我试过了:

但它没有用。我只是做错了还是不支持?

0 投票
3 回答
7082 浏览

continuous-integration - 与 React Native 持续集成

我是 iOS 新手,有人可以告诉我如何设置 CI 以响应本机吗?我目前使用 codeship,但我认为他们没有为 iOS 提供任何东西。对任何支持 bitbucket 的托管 CI 工具有什么建议吗?谢谢

0 投票
1 回答
2747 浏览

ios - ListView 部分数据(react-native)

我想在 react-native 中创建一个两层(部分 >> 条目)列表视图,类似于 UIExplorerApp 中的 ListViewPagingExample,但使用 blob 数据/json 来填充部分信息。此外,我对将哪些参数值传递给 cloneWithRowsAndSections 感到困惑。

从文档( https://facebook.github.io/react-native/docs/listview.html#content )中找不到有关上述主题的任何内容,但仅提及它是可能的。一些例子会有所帮助。

谢谢

0 投票
1 回答
2092 浏览

javascript - autoGenerateWrapperClass 为 null 反应原生

我正在为 scala-js 中的 react-native 编写包装器

组件注册良好,但在创建视图元素时失败!

null 不是函数(评估'autoGenerateWrapperClass(tag)')“

完整的堆栈跟踪:

在调试此功能时

标签值为 ReactElement

注意:上面的代码在带有 div 标签/反应组件的 reactjs 中工作正常。

编辑:它的问题来自 scalajs-react builder ,它遵循 ReactJS 渲染 API 而不是 AppRegistry ,关闭问题。