Nitoi Eliza-Maria
@ElizaNitoi
React-Native Developer
http://bit.ly/canIReactNative
{
components: true, console.log: true
} stateManagement: true,
lifecycleMethods: true, {
network: false,
brakpoints: false
} console.log('I am your best friend') Native debugging tools (XCode - Debug View Hierarchy)
Design
let AndroidPhones = [
'Samsung',
'Huawei',
'Xiaomi',
'Oppo',
'Motorola',
'LG',
'Vivo',
'Lenovo',
'Sony',
'Asus',
'OnePlus',
'HTC',
...
]let Iphones = [
'Iphone 5s',
'Iphone 6',
'Iphone 6Plus',
'Iphone 7',
'Iphone 7Plus',
'Iphone 8',
'Iphone 8Plus',
'Iphone SE',
'Iphone X',
'Iphone XR',
'Iphone XS',
'Iphone XS Max'
]PixelRatio.get() === 1 // mdpi Android devices
PixelRatio.get() === 1.5 //hdpi Android devices
const StyledView = styled.View`
background-color: 'red'
`
const StyledView = () => {
return (
<View style={styles.color} />
)
}
const styles = Stylesheet.create({
color: {
backgroundColor: 'red'
}
})Deploying
Changes
// React deploy
this.deployChanges()
.then(() => console.log('users have the changes'))
.catch(() => console.log('try again')) this.waitForUsersToUpdate()
.then(() => console.log('users see changes'))
.catch(() => console.log('-_-'))// Android and IOS deploys
this.makeNewBuilds()
.then(() => {
this.uploadToStoresAndWaitForReview()
.then(() => {
})
.catch(() => console.log('fix App Store review'))this.deployChanges()
.then(() => console.log('users have the changes'))
.catch(() => console.log('try again'))Publish build from terminal
CodePush sends JS bundle to Cloud
Checks if new updates
Sends the JS bundle
New update is installed
React Native community
you
Phone manufacturers
Changes coming from ...
well to changes
Nitoi Eliza-Maria
@ElizaNitoi
React-Native Developer
http://bit.ly/canIReactNative