react-native-ios

Select a row in ListView react-native to get detail

谁说我不能喝 提交于 2019-12-10 04:54:53
问题 i'm new in react-native. I saw an example in https://facebook.github.io/react-native/docs/sample-application-movies.html . It is building a movies app that fetch movies and display them in a ListView. How can we select a row to get its detail data and display it in other view? Please help. thanks :) Here's what i've done so far: /** * Sample React Native App * https://github.com/facebook/react-native */ import React, { Component, } from 'react'; import { AppRegistry, Image, ListView,

A Custom Tab bar with two images in each tab using react navigation?

不想你离开。 提交于 2019-12-09 17:38:56
问题 I am creating an app using React Native for ios. Instead of having an active tintColor I want to have two little triangles (another image/icon) which appears when you are on the selected tab. It is important that the center y axis of the triangles is = to the y axis of the bottom of the tabbar image and that the tab icon is in the center of the triangles as seen below. At the moment I have the tab bar, the icons and navigation working - I just don't know how to make the triangles appear: ICON

React-native - Build failed due to double-conversion

a 夏天 提交于 2019-12-09 16:24:21
问题 I have created new react-native project through terminal. react-native init PlayWithAnimation when I run the react-native app through Xcode. I got this error. /bin/sh -c \"/Users/sumit/Desktop/React\ Native/RNN/ios/build/Build/Intermediates/React.build/Debug-iphonesimulator/double-conversion.build/Script-190EE32F1E6A43DE00A8543A.sh\" /Users/sumit/Desktop/React >Native/RNN/ios/build/Build/Intermediates/React.build/Debug-iphonesimulator/double-conversion.build/Script-190EE32F1E6A43DE00A8543A.sh

React' findNodeHandle method stopped working

江枫思渺然 提交于 2019-12-09 14:21:49
问题 After upgrade to 0.26.0-rc version, this line: React.findNodeHandle(this.refs.myRef) Throws this error message: Unhandled JS Exception: _react2.default.findNodeHandle is not a function. I'm importing React with this: import React from 'react'; Docs still say: "As always, to obtain a native node handle for a component, you can use React.findNodeHandle(component)." 回答1: Now the function may be used without object: import { ... findNodeHandle, ... } from 'react-native'; And call it directly:

FBSDKCoreKit/FBSDKCoreKit.h file not found error react-native ios

风格不统一 提交于 2019-12-09 13:18:57
问题 Try to install Facebook SDK to react natiove IOS. I have FBSDKCoreKit/FBSDKCoreKit.h file not found error and spent several hours trying to solve it with different solutions, but can't understand whats going wrong(( Any ideas? react-native 0.40 react-native-fsdk 0.5.0 facebook sdk: 4.19.0 回答1: EDIT: I recommend using CocoaPods so you don't need to download/update the sdk manually. If you downloaded the sdk manually, try this: Open your ~/Documents/FacebookSDK folder; Check if it has these

React Native STUCK starting packager

纵然是瞬间 提交于 2019-12-08 15:55:52
问题 For some reason when I want to start my React Native project, it's stucks at 'Starting Packager...' part. I tried to delete the node packages, and reinstall them, intall them via yarn, npm, but no luck. I got no idea how should I fix this :/ (so awkward) 回答1: I had the same issue. I solved it by changing react-native-scripts version from "^1.14.1" to "1.14.0" and run npm install again. 回答2: after a long search I found a solution for this problem: this problem is caused by another watchman

Native component for “AIRMap” does not exist

最后都变了- 提交于 2019-12-08 15:18:31
react-native: 0.53.3 react-native-maps@0.20.1 I'm trying to use react-native-maps and I keep getting this error. This is in a fresh project: react-native init maps cd maps/ npm install --save react-native-maps react-native run-ios And in App.js I've added this: ... import MapView from 'react-native-maps'; export default class App extends Component<Props> { render() { return ( <View> <MapView initialRegion={{ latitude: 37.78825, longitude: -122.4324, latitudeDelta: 0.0922, longitudeDelta: 0.0421, }} /> </View> ); } } This seems to be the bare minimum to get this running, but my iOS simulator is

React-native Airbnb-Maps: How do I render a button inside the airbnb maps pop-up box?

前提是你 提交于 2019-12-08 07:20:28
I am trying to render a button which I can use to redirect to another page within the description page (the pop-up-box if you select a marker) using AirBnb maps (using MapView.Markers ). I am not sure how to achieve this. Currently my markers look as follow: const markers = [{ longitude: 8.545592, latitude: 47.366465, description: "Bike 1", title: "Bike 1" }, { longitude: 8.545892, latitude: 47.366365, description: "Bike 2", title: "Bike 2" } ]; Whenever I try to input JSX into a text, I get a NSMutableDictionary cannot be converted to NSString error. (When I do this: const markers = [{

Native component for “AIRMap” does not exist

£可爱£侵袭症+ 提交于 2019-12-08 04:46:32
问题 react-native: 0.53.3 react-native-maps@0.20.1 I'm trying to use react-native-maps and I keep getting this error. This is in a fresh project: react-native init maps cd maps/ npm install --save react-native-maps react-native run-ios And in App.js I've added this: ... import MapView from 'react-native-maps'; export default class App extends Component<Props> { render() { return ( <View> <MapView initialRegion={{ latitude: 37.78825, longitude: -122.4324, latitudeDelta: 0.0922, longitudeDelta: 0

protocol extension doesn't work with RCT_EXPORT_VIEW_PROPERTY?

爱⌒轻易说出口 提交于 2019-12-08 04:01:49
问题 I have a partial base class RNChartBaseView (protocol and extension), and bunch of subclass like RNLineChartView, RNBarChartView etc. RNChartBaseView.swift protocol RNChartBaseView { associatedtype T: ChartViewBase; associatedtype U: ChartDataEntryBase; var chart: T { get } func createEntries(_ data: NSDictionary) -> [U]; func setData(_ data: NSDictionary); } extension RNChartBaseView { func setData(_ data: NSDictionary) { let chartData = createEntries(data); chart.data = chartData; } }