This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ios | |
pod init |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo gem install cocoapods |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
react-native link react-native-maps |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm install --save react-native-maps |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
react-native init googleMapsAirbnb | |
cd googleMapsAirbnb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"key":1, | |
"name":"Suits", | |
"image":"https://static.tvmaze.com/uploads/images/medium_portrait/0/2432.jpg" | |
}, | |
{ | |
"key":2, | |
"name":"Modern Family", | |
"image":"https://static.tvmaze.com/uploads/images/medium_portrait/0/628.jpg" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<TextInput | |
style={styles.textInput} | |
onChangeText={(text) => this.filterSearch(text)} | |
value={this.state.text} | |
/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
filterSearch(text){ | |
this.setState({text}) | |
let newData = this.dataFilter(text, this.state.rawData); | |
this.setState({ | |
dataSource: this.state.dataSource.cloneWithRows(newData), | |
isLoaded: true, | |
empty: false | |
}) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
renderRow(rowData){ | |
return ( | |
<TouchableHighlight style={styles.containerCell}> | |
<View> | |
<View style={styles.footerContainer}> | |
<View style={styles.footerTextContainer}> | |
<Text style={styles.text}>{rowData.name}</Text> | |
<Text style={[styles.text, styles.textTitle]}>{rowData.number}</Text> | |
<Text style={[styles.text, styles.textBy]}>By {rowData.airdate}</Text> | |
</View> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ListView | |
enableEmptySections={true} | |
renderRow={this.renderRow.bind(this)} | |
dataSource={this.state.dataSource} | |
/> |