SlideShare una empresa de Scribd logo
1 de 67
React Native By Example
Android
App
iOS
App
Java / Kotlin Swift / Objective-CLanguage
XML XIBViews
Android Studio
Grandle
XCODETools
 Instant Platform API access
 Third party libraries
 Great user experience
Pros:
Cons:
 TWO DIFFERENT APPLICATIONS
 TWO DIFFERENT TEAMS
 TWICE NUMBER OF BUGS
Flutter
Hybrid Approach!
Apache Cordova
 Portability
 It is just JavaScript, HTML5, CSS3
 Re-use the codebase from WebApplication
WebView
 Usually poor performance
 Bad user experience
 Requires C#
 Runs on Mono VM
 Stable with good community
 Supported by Microsoft
 Xamarin 2.0 was released in February 2013
 Dart language
 Reactive framework
 Supported by Google
Flutter
 Still beta
Learn once, write anywhere
 JavaScript (ES6+)
 React (JSX)
 Native UI
 Flexbox
 CSS
 Polyfills
const WebApp = () => (
<div>Hello World!</div>
)
import {View} from 'react-native’
const MobileApp = () => (
<View><Text>Hello World!</Text></View>
)
const WebApp = () => (
<div>Hello World!</div>
)
REACT REACT-DOM
BROWSER
DOM
import {View} from 'react-native’
const MobileApp = () => (
<View><Text>Hello World!</Text></View>
)
REACT REACT-NATIVE
iOS Native
Components
Android Native
Components
REACT
REACT-DOM
REACT-NATIVE
REACT-VR
REACT-ART
…
REACT-NATIVE-MAC-OS
REACT-NATIVE-WINDOWS
REACT-D3
REACT-PIXI
Virtual DOM
RENDERERS
react-native init MyProject
react-native run-android
react-native run-ios
 Minimal "Time to Hello World”
 Easy share your code
 One Build Tool
create-react-native-app MyProject
 No native modules
import React, { Component } from 'react';
import {Text, View, Button} from 'react-native';
export default class App extends Component {
render() {
return (
<View>
<Text>
Welcome to React Native!
</Text>
<Button
title="Press Me!"
onPress={() => {alert('Thanks dude!')}}
/>
</View>
);
}
}
Component styles
<Touchable
onPress={this.onServerSignInPress}
style={{marginTop: 24}}
>
<View style={s.signInButton}>
<Text style={s.signInButtonText}>
SING IN
</Text>
</View>
</Touchable>
SignInButtonStyles.js
import {StyleSheet} from 'react-native'
export default StyleSheet.create({
signInButton: {
width: 280,
height: 48,
borderRadius: 24,
backgroundColor: "#59acfa",
alignItems: 'center’,
justifyContent: 'center’
},
signInButtonText: {
color: "#FFF",
fontWeight: 'bold’,
fontSize: 14
}
})
MAIN UI
THREAD
NATIVE
MODULES
JavaScript
THREAD
“LAYOUT”
THREAD
Start
JS Startup & Render
Calc Layout
Create
Views
JavaScript Native
The Bridge
(MessageQueue.js)
JSCore / V8 (VM)
Single Thread
ObjectiveC / Java
Main UI Thread
import MessageQueue from 'react-native/Libraries/BatchedBridge/MessageQueue'
MessageQueue.spy((info)=>console.log("event!", info))
<View></View>
new android.view.View(context); [[UIView alloc] init]
RCTViewManagerReactViewManager
View
Button
FlatList
Image
ListView
Modal
Picker
ScrollView
WebView
Slider
StatusBar
Switch
Text
TextInput
Touchable
…
DatePickerIOS
DrawerLayoutAndroid
MaskedViewIOS
NavigatorIOS
ProgressBarAndroid
ProgressViewIOS
TabBarIOS
…
<View style={{
flex: 1,
marginTop: 50,
marginBottom: 30,
flexDirection: 'column',
alignItems: 'center',
justifyContent: 'space-between',
}}>
<View style={{width: 100, height: 100, backgroundColor: '#2ecc71'}} />
<View style={{width: 100, height: 100, backgroundColor: '#27ae60'}} />
<View style={{width: 100, height: 100, backgroundColor: '#16a085'}} />
</View>
• A cross-platform layout engine
• Written in C/C++
• Compatible with Android / iOS
Yoga
Network
Clipboard
StyleSheet
Vibration
Platform
AsyncStorage
Systrace
Geolocation
AppState
…
try {
const response = await fetch('https://example.com/json')
const posts = await response.json()
this.setState({loading: false, posts})
} catch (e) {
this.setState({loading: false, error: true})
}
HTTP Request example
Add an open-source component
import LinearGradient from 'react-native-linear-gradient';
<LinearGradient colors={['#2a5743', '#14456f']}>
<View />
</LinearGradient>
1) yarn add react-native-linear-gradient
2) react-native link
react-native link
android/app/build.gradle
android/app/src/…/MainApplication.java
android/settings.gradle
ios/MyProject.xcodeproj/project.pbxproj
• No CSS transitions
• No CSS animations
React Native Animations
• Animated.{View,Image,Text,ScrollView}
• Animated.Value()
• Animated.createAnimatedComponent(View)
Animated API
state = {
fadeAnim: new Animated.Value(0),
}
render() {
return (
<Animated.View style={{opacity: this.state.fadeAnim}}>
{this.props.children}
</Animated.View>
);
}
Animated API
componentDidMount() {
Animated.timing(
this.state.fadeAnim,
{
toValue: 1,
duration: 1000,
}
).start();
} useNativeDriver: true, // <-- Add this
ViewPager.js
ScrollView
ViewPagerAndroid
• MyComponent.android.js
• MyComponent.ios.js
• Platform.OS === ‘android’
• Platform.OS === ‘ios'
Platform specific code
PJSIP
• SIP stack
• Audio/Video streaming
• Compatible with Android / iOS
• Get the configuration from server
• Through the bridge pass this configuration to
Native Module
• Once library is initialized emit events like new
incoming call
PjSIP binding for React Native
Call Native code from JavaScript
import {NativeModules} from 'react-native';
NativeModules.PjSipModule.methodName(configuration, (successful, data) => {
// …
});
Native Module
@interface PjSipModule : NSObject <RCTBridgeModule>
 RCT_EXPORT_MODULE();
 RCT_EXPORT_METHOD(method)
 (NSDictionary *)constantsToExport;
Native Module
RCT_EXPORT_METHOD(answerCall: (int) callId callback:(RCTResponseSenderBlock) callback) {
PjSipEndpoint* endpoint = [PjSipEndpoint instance];
PjSipCall *call = [endpoint findCall:callId];
if (call) {
[call answer];
[endpoint pauseParallelCalls:call]; // put other calls on hold
callback(@[@TRUE]);
} else {
callback(@[@FALSE, @"Call not found"]);
}
}
public class PjSipModule extends ReactContextBaseJavaModule
Native Module
 @ReactMethod
 public Map<String, Object> getConstants()
Native Module
@ReactMethod
public void answerCall(int callId, Callback callback) {
int callbackId = receiver.register(callback);
Intent intent = PjActions.createAnswerCallIntent(callbackId, callId, getReactApplicationContext());
getReactApplicationContext().startService(intent);
}
Subscribe to Native Event
import {DeviceEventEmitter} from 'react-native';
DeviceEventEmitter.addListener(‘eventName', (data) => {
// ...
});
Emit events from Native Module
[self emmitEvent:@”eventName"
body:[call toJsonDictionary]];
reactContext
.getJSModule(DeviceEventManagerModule.RCTDeviceEventEmitter.class)
.emit(eventName, data);
RemoteVideoView
LocalVideoView
import {requireNativeComponent} from 'react-native';
export default requireNativeComponent('PjSipRemoveVideoView');
RemoteVideoView.js
import RemoteVideoView from 'react-native-pjsip/src/RemoteVideoView’
export const VideoCall = ({media}) => (
<View style={s.container}>
<RemoteVideoView
windowId={media.videoStream.windowId}
objectFit="contain"
/>
</View>
)
VideoCall.js
Native Component
@interface PjSipRemoteVideoViewManager : RCTViewManager
RCT_EXPORT_VIEW_PROPERTY(name, type)
RCT_CUSTOM_VIEW_PROPERTY(name, type, viewClass)
@implementation PjSipRemoteVideoViewManager
RCT_EXPORT_MODULE()
-(UIView *) view {
return [[PjSipVideo alloc] init];
}
RCT_CUSTOM_VIEW_PROPERTY(windowId, NSString, PjSipVideo) {
pjsua_vid_win_id windowId = [[RCTConvert NSNumber:json] intValue];
[view setWindowId:windowId];
}
@end
Native Component
public class PjSipRemoteVideoViewManager extends
SimpleViewManager<PjSipRemoteVideo>
Native Component
 @ReactProp(name = "windowId")
 createViewInstance(ThemedReactContext reactContext)
Native Component
public class PjSipRemoteVideoViewManager extends SimpleViewManager<PjSipRemoteVideo> {
@Override public String getName() {
return "PjSipRemoteVideoView";
}
@ReactProp(name = "windowId")
public void setWindowId(PjSipRemoteVideo view, int windowId) {
view.setWindowId(windowId);
}
@Override protected PjSipRemoteVideo createViewInstance(ThemedReactContext reactContext) {
return new PjSipRemoteVideo(reactContext);
}
}
Navigation
• Navigator
• react-
community/react-
navigation
JavaScript Native
• wix/react-native-
navigation
• airbnb/native-
navigation
• Removed since 0.44.3
• Pure JS implementation
• Lack of native look and feel
• Poor performance between screen
change
Navigator
 Native implementation
 Different React roots for each Screen
 Great UX and cool features
 Non-trivial installation and further RN
upgrades
 Still doesn’t cover all props and APIs
that platform has
wix/react-native-navigation
cd ./ios && xcodebuild -scheme Carusto -configuration Release archive -
archivePath ./Jenkins.xcarchive
cd ./ios && xcodebuild -exportArchive -archivePath "./Jenkins.xcarchive" -
exportPath "./Jenkins.ipa" -exportOptionsPlist "./Jenkins.plist
Android APK
iOS IPA
cd ./android && ./gradlew assembleRelease
• JS errors in production will crash the app
• Non trivial way to get the logs from real
device
Catch the bugs in production
Just re-use the same knowledge form your Web
experience (e.g. Jest, Enzyme, etc..)
Unit Testing
 Quality of open-source components
 Frequent updates
 Non critical bugs
Summary
 Fast prototyping and development for two
platforms
 React / JS environment
 Share the codebase with web-app
 Native look and feel
Summary
Thank You!

Más contenido relacionado

La actualidad más candente

Making React Native UI Components with Swift
Making React Native UI Components with SwiftMaking React Native UI Components with Swift
Making React Native UI Components with SwiftRay Deck
 
Workshop 25: React Native - Components
Workshop 25: React Native - ComponentsWorkshop 25: React Native - Components
Workshop 25: React Native - ComponentsVisual Engineering
 
Connect.js - Exploring React.Native
Connect.js - Exploring React.NativeConnect.js - Exploring React.Native
Connect.js - Exploring React.Nativejoshcjensen
 
2011 a grape odyssey
2011   a grape odyssey2011   a grape odyssey
2011 a grape odysseyMike Hagedorn
 
Apache Cordova In Action
Apache Cordova In ActionApache Cordova In Action
Apache Cordova In ActionHazem Saleh
 
How React Native, Appium and me made each other shine @Frontmania 16-11-2018
How React Native, Appium and me made each other shine @Frontmania 16-11-2018How React Native, Appium and me made each other shine @Frontmania 16-11-2018
How React Native, Appium and me made each other shine @Frontmania 16-11-2018Wim Selles
 
Connect.js 2015 - Building Native Mobile Applications with Javascript
Connect.js 2015 - Building Native Mobile Applications with JavascriptConnect.js 2015 - Building Native Mobile Applications with Javascript
Connect.js 2015 - Building Native Mobile Applications with Javascriptjoshcjensen
 
Composable and streamable Play apps
Composable and streamable Play appsComposable and streamable Play apps
Composable and streamable Play appsYevgeniy Brikman
 
Node.js vs Play Framework (with Japanese subtitles)
Node.js vs Play Framework (with Japanese subtitles)Node.js vs Play Framework (with Japanese subtitles)
Node.js vs Play Framework (with Japanese subtitles)Yevgeniy Brikman
 
Building scalable applications with angular js
Building scalable applications with angular jsBuilding scalable applications with angular js
Building scalable applications with angular jsAndrew Alpert
 
Integration Testing With ScalaTest and MongoDB
Integration Testing With ScalaTest and MongoDBIntegration Testing With ScalaTest and MongoDB
Integration Testing With ScalaTest and MongoDBMichal Bigos
 
AngularJS Unit Test
AngularJS Unit TestAngularJS Unit Test
AngularJS Unit TestChiew Carol
 
Academy PRO: React native - navigation
Academy PRO: React native - navigationAcademy PRO: React native - navigation
Academy PRO: React native - navigationBinary Studio
 
Workshop 27: Isomorphic web apps with ReactJS
Workshop 27: Isomorphic web apps with ReactJSWorkshop 27: Isomorphic web apps with ReactJS
Workshop 27: Isomorphic web apps with ReactJSVisual Engineering
 
Android programming -_pushing_the_limits
Android programming -_pushing_the_limitsAndroid programming -_pushing_the_limits
Android programming -_pushing_the_limitsDroidcon Berlin
 
Promises are so passé - Tim Perry - Codemotion Milan 2016
Promises are so passé - Tim Perry - Codemotion Milan 2016Promises are so passé - Tim Perry - Codemotion Milan 2016
Promises are so passé - Tim Perry - Codemotion Milan 2016Codemotion
 

La actualidad más candente (20)

Making React Native UI Components with Swift
Making React Native UI Components with SwiftMaking React Native UI Components with Swift
Making React Native UI Components with Swift
 
Workshop 25: React Native - Components
Workshop 25: React Native - ComponentsWorkshop 25: React Native - Components
Workshop 25: React Native - Components
 
Connect.js - Exploring React.Native
Connect.js - Exploring React.NativeConnect.js - Exploring React.Native
Connect.js - Exploring React.Native
 
2011 a grape odyssey
2011   a grape odyssey2011   a grape odyssey
2011 a grape odyssey
 
Apache Cordova In Action
Apache Cordova In ActionApache Cordova In Action
Apache Cordova In Action
 
How React Native, Appium and me made each other shine @Frontmania 16-11-2018
How React Native, Appium and me made each other shine @Frontmania 16-11-2018How React Native, Appium and me made each other shine @Frontmania 16-11-2018
How React Native, Appium and me made each other shine @Frontmania 16-11-2018
 
Play vs Rails
Play vs RailsPlay vs Rails
Play vs Rails
 
Connect.js 2015 - Building Native Mobile Applications with Javascript
Connect.js 2015 - Building Native Mobile Applications with JavascriptConnect.js 2015 - Building Native Mobile Applications with Javascript
Connect.js 2015 - Building Native Mobile Applications with Javascript
 
Composable and streamable Play apps
Composable and streamable Play appsComposable and streamable Play apps
Composable and streamable Play apps
 
Rails Best Practices
Rails Best PracticesRails Best Practices
Rails Best Practices
 
Node.js vs Play Framework (with Japanese subtitles)
Node.js vs Play Framework (with Japanese subtitles)Node.js vs Play Framework (with Japanese subtitles)
Node.js vs Play Framework (with Japanese subtitles)
 
AngularJS - TechTalk 3/2/2014
AngularJS - TechTalk 3/2/2014AngularJS - TechTalk 3/2/2014
AngularJS - TechTalk 3/2/2014
 
Sane Async Patterns
Sane Async PatternsSane Async Patterns
Sane Async Patterns
 
Building scalable applications with angular js
Building scalable applications with angular jsBuilding scalable applications with angular js
Building scalable applications with angular js
 
Integration Testing With ScalaTest and MongoDB
Integration Testing With ScalaTest and MongoDBIntegration Testing With ScalaTest and MongoDB
Integration Testing With ScalaTest and MongoDB
 
AngularJS Unit Test
AngularJS Unit TestAngularJS Unit Test
AngularJS Unit Test
 
Academy PRO: React native - navigation
Academy PRO: React native - navigationAcademy PRO: React native - navigation
Academy PRO: React native - navigation
 
Workshop 27: Isomorphic web apps with ReactJS
Workshop 27: Isomorphic web apps with ReactJSWorkshop 27: Isomorphic web apps with ReactJS
Workshop 27: Isomorphic web apps with ReactJS
 
Android programming -_pushing_the_limits
Android programming -_pushing_the_limitsAndroid programming -_pushing_the_limits
Android programming -_pushing_the_limits
 
Promises are so passé - Tim Perry - Codemotion Milan 2016
Promises are so passé - Tim Perry - Codemotion Milan 2016Promises are so passé - Tim Perry - Codemotion Milan 2016
Promises are so passé - Tim Perry - Codemotion Milan 2016
 

Similar a React native by example by Vadim Ruban

React Native for multi-platform mobile applications
React Native for multi-platform mobile applicationsReact Native for multi-platform mobile applications
React Native for multi-platform mobile applicationsMatteo Manchi
 
React native introduction
React native introductionReact native introduction
React native introductionInnerFood
 
React & Redux for noobs
React & Redux for noobsReact & Redux for noobs
React & Redux for noobs[T]echdencias
 
Building Universal Web Apps with React ForwardJS 2017
Building Universal Web Apps with React ForwardJS 2017Building Universal Web Apps with React ForwardJS 2017
Building Universal Web Apps with React ForwardJS 2017Elyse Kolker Gordon
 
React native introduction
React native introductionReact native introduction
React native introductionInnerFood
 
Lessons from a year of building apps with React Native
Lessons from a year of building apps with React NativeLessons from a year of building apps with React Native
Lessons from a year of building apps with React NativeRyan Boland
 
An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...
An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...
An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...GreeceJS
 
Django + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar DjangoDjango + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar DjangoJavier Abadía
 
Gdg dev fest hybrid apps your own mini-cordova
Gdg dev fest hybrid apps  your own mini-cordovaGdg dev fest hybrid apps  your own mini-cordova
Gdg dev fest hybrid apps your own mini-cordovaAyman Mahfouz
 
125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용NAVER D2
 
Crossing platforms with JavaScript & React
Crossing platforms with JavaScript & React Crossing platforms with JavaScript & React
Crossing platforms with JavaScript & React Robert DeLuca
 
Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017
Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017
Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017Codemotion
 
Workshop 26: React Native - The Native Side
Workshop 26: React Native - The Native SideWorkshop 26: React Native - The Native Side
Workshop 26: React Native - The Native SideVisual Engineering
 
Building cross-platform mobile apps with React Native (Jfokus 2017)
Building cross-platform mobile apps with React Native (Jfokus 2017)Building cross-platform mobile apps with React Native (Jfokus 2017)
Building cross-platform mobile apps with React Native (Jfokus 2017)Maarten Mulders
 
Google Web Toolkits
Google Web ToolkitsGoogle Web Toolkits
Google Web ToolkitsYiguang Hu
 
JS Fest 2018. Илья Иванов. Введение в React-Native
JS Fest 2018. Илья Иванов. Введение в React-NativeJS Fest 2018. Илья Иванов. Введение в React-Native
JS Fest 2018. Илья Иванов. Введение в React-NativeJSFestUA
 
React 101 by Anatoliy Sieryi
React 101 by Anatoliy Sieryi React 101 by Anatoliy Sieryi
React 101 by Anatoliy Sieryi Binary Studio
 
React Native Androidはなぜ動くのか
React Native Androidはなぜ動くのかReact Native Androidはなぜ動くのか
React Native Androidはなぜ動くのかYukiya Nakagawa
 
React: JSX and Top Level API
React: JSX and Top Level APIReact: JSX and Top Level API
React: JSX and Top Level APIFabio Biondi
 

Similar a React native by example by Vadim Ruban (20)

React Native for multi-platform mobile applications
React Native for multi-platform mobile applicationsReact Native for multi-platform mobile applications
React Native for multi-platform mobile applications
 
React native introduction
React native introductionReact native introduction
React native introduction
 
React & Redux for noobs
React & Redux for noobsReact & Redux for noobs
React & Redux for noobs
 
Building Universal Web Apps with React ForwardJS 2017
Building Universal Web Apps with React ForwardJS 2017Building Universal Web Apps with React ForwardJS 2017
Building Universal Web Apps with React ForwardJS 2017
 
React native introduction
React native introductionReact native introduction
React native introduction
 
Lessons from a year of building apps with React Native
Lessons from a year of building apps with React NativeLessons from a year of building apps with React Native
Lessons from a year of building apps with React Native
 
An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...
An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...
An Emoji Introduction to React Native (Panagiotis Vourtsis, Senior Front End ...
 
Django + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar DjangoDjango + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar Django
 
Gdg dev fest hybrid apps your own mini-cordova
Gdg dev fest hybrid apps  your own mini-cordovaGdg dev fest hybrid apps  your own mini-cordova
Gdg dev fest hybrid apps your own mini-cordova
 
125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용
 
Crossing platforms with JavaScript & React
Crossing platforms with JavaScript & React Crossing platforms with JavaScript & React
Crossing platforms with JavaScript & React
 
Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017
Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017
Going fullstack React(ive) - Paulo Lopes - Codemotion Amsterdam 2017
 
Workshop 26: React Native - The Native Side
Workshop 26: React Native - The Native SideWorkshop 26: React Native - The Native Side
Workshop 26: React Native - The Native Side
 
Building cross-platform mobile apps with React Native (Jfokus 2017)
Building cross-platform mobile apps with React Native (Jfokus 2017)Building cross-platform mobile apps with React Native (Jfokus 2017)
Building cross-platform mobile apps with React Native (Jfokus 2017)
 
Google Web Toolkits
Google Web ToolkitsGoogle Web Toolkits
Google Web Toolkits
 
JS Fest 2018. Илья Иванов. Введение в React-Native
JS Fest 2018. Илья Иванов. Введение в React-NativeJS Fest 2018. Илья Иванов. Введение в React-Native
JS Fest 2018. Илья Иванов. Введение в React-Native
 
React 101 by Anatoliy Sieryi
React 101 by Anatoliy Sieryi React 101 by Anatoliy Sieryi
React 101 by Anatoliy Sieryi
 
React Native Androidはなぜ動くのか
React Native Androidはなぜ動くのかReact Native Androidはなぜ動くのか
React Native Androidはなぜ動くのか
 
React: JSX and Top Level API
React: JSX and Top Level APIReact: JSX and Top Level API
React: JSX and Top Level API
 
Vue js and Dyploma
Vue js and DyplomaVue js and Dyploma
Vue js and Dyploma
 

Más de Lohika_Odessa_TechTalks

OAuth2 Authorization Server Under the Hood
OAuth2 Authorization Server Under the HoodOAuth2 Authorization Server Under the Hood
OAuth2 Authorization Server Under the HoodLohika_Odessa_TechTalks
 
Debugging Microservices - key challenges and techniques - Microservices Odesa...
Debugging Microservices - key challenges and techniques - Microservices Odesa...Debugging Microservices - key challenges and techniques - Microservices Odesa...
Debugging Microservices - key challenges and techniques - Microservices Odesa...Lohika_Odessa_TechTalks
 
Design and Evolution of APIs in Microservice Architecture
Design and Evolution of APIs in Microservice ArchitectureDesign and Evolution of APIs in Microservice Architecture
Design and Evolution of APIs in Microservice ArchitectureLohika_Odessa_TechTalks
 
Prometheus: infrastructure and application monitoring in kubernetes cluster
Prometheus: infrastructure and application monitoring in kubernetes clusterPrometheus: infrastructure and application monitoring in kubernetes cluster
Prometheus: infrastructure and application monitoring in kubernetes clusterLohika_Odessa_TechTalks
 
Architectural peripherals of react by Vadym Zhiltsov
Architectural peripherals of react by Vadym ZhiltsovArchitectural peripherals of react by Vadym Zhiltsov
Architectural peripherals of react by Vadym ZhiltsovLohika_Odessa_TechTalks
 
Congratulations, you have been promoted to a manager role. You`ve got new pro...
Congratulations, you have been promoted to a manager role. You`ve got new pro...Congratulations, you have been promoted to a manager role. You`ve got new pro...
Congratulations, you have been promoted to a manager role. You`ve got new pro...Lohika_Odessa_TechTalks
 
"Don't touch me and give me my money" or how motivate people who can but don...
"Don't touch me and give me my money" or  how motivate people who can but don..."Don't touch me and give me my money" or  how motivate people who can but don...
"Don't touch me and give me my money" or how motivate people who can but don...Lohika_Odessa_TechTalks
 
Docker based Architecture by Denys Serdiuk
Docker based Architecture by Denys SerdiukDocker based Architecture by Denys Serdiuk
Docker based Architecture by Denys SerdiukLohika_Odessa_TechTalks
 
SparkSpark in the Big Data dark by Sergey Levandovskiy
SparkSpark in the Big Data dark by Sergey Levandovskiy  SparkSpark in the Big Data dark by Sergey Levandovskiy
SparkSpark in the Big Data dark by Sergey Levandovskiy Lohika_Odessa_TechTalks
 
Burnout and how to avoid it in your team. Responsible person's issue by Andre...
Burnout and how to avoid it in your team. Responsible person's issue by Andre...Burnout and how to avoid it in your team. Responsible person's issue by Andre...
Burnout and how to avoid it in your team. Responsible person's issue by Andre...Lohika_Odessa_TechTalks
 
Performance evaluation process as a way to empower your employees and help th...
Performance evaluation process as a way to empower your employees and help th...Performance evaluation process as a way to empower your employees and help th...
Performance evaluation process as a way to empower your employees and help th...Lohika_Odessa_TechTalks
 
Selenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalks
Selenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalksSelenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalks
Selenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalksLohika_Odessa_TechTalks
 
" Performance testing for Automation QA - why and how " by Andrey Kovalenko f...
" Performance testing for Automation QA - why and how " by Andrey Kovalenko f..." Performance testing for Automation QA - why and how " by Andrey Kovalenko f...
" Performance testing for Automation QA - why and how " by Andrey Kovalenko f...Lohika_Odessa_TechTalks
 
"WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te...
"WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te..."WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te...
"WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te...Lohika_Odessa_TechTalks
 

Más de Lohika_Odessa_TechTalks (20)

OAuth2 Authorization Server Under the Hood
OAuth2 Authorization Server Under the HoodOAuth2 Authorization Server Under the Hood
OAuth2 Authorization Server Under the Hood
 
Debugging Microservices - key challenges and techniques - Microservices Odesa...
Debugging Microservices - key challenges and techniques - Microservices Odesa...Debugging Microservices - key challenges and techniques - Microservices Odesa...
Debugging Microservices - key challenges and techniques - Microservices Odesa...
 
Design and Evolution of APIs in Microservice Architecture
Design and Evolution of APIs in Microservice ArchitectureDesign and Evolution of APIs in Microservice Architecture
Design and Evolution of APIs in Microservice Architecture
 
Micro-frontends – is it a new normal?
Micro-frontends – is it a new normal?Micro-frontends – is it a new normal?
Micro-frontends – is it a new normal?
 
Multithreading in go
Multithreading in goMultithreading in go
Multithreading in go
 
Druid - Interactive Analytics At Scale
Druid - Interactive Analytics At ScaleDruid - Interactive Analytics At Scale
Druid - Interactive Analytics At Scale
 
DevOps Odessa #TechTalks 21.01.2020
DevOps Odessa #TechTalks 21.01.2020DevOps Odessa #TechTalks 21.01.2020
DevOps Odessa #TechTalks 21.01.2020
 
Jenkins' shared libraries in action
Jenkins' shared libraries in actionJenkins' shared libraries in action
Jenkins' shared libraries in action
 
Prometheus: infrastructure and application monitoring in kubernetes cluster
Prometheus: infrastructure and application monitoring in kubernetes clusterPrometheus: infrastructure and application monitoring in kubernetes cluster
Prometheus: infrastructure and application monitoring in kubernetes cluster
 
Architectural peripherals of react by Vadym Zhiltsov
Architectural peripherals of react by Vadym ZhiltsovArchitectural peripherals of react by Vadym Zhiltsov
Architectural peripherals of react by Vadym Zhiltsov
 
Aws lambda by Leonid Amigud
Aws lambda by Leonid AmigudAws lambda by Leonid Amigud
Aws lambda by Leonid Amigud
 
Congratulations, you have been promoted to a manager role. You`ve got new pro...
Congratulations, you have been promoted to a manager role. You`ve got new pro...Congratulations, you have been promoted to a manager role. You`ve got new pro...
Congratulations, you have been promoted to a manager role. You`ve got new pro...
 
"Don't touch me and give me my money" or how motivate people who can but don...
"Don't touch me and give me my money" or  how motivate people who can but don..."Don't touch me and give me my money" or  how motivate people who can but don...
"Don't touch me and give me my money" or how motivate people who can but don...
 
Docker based Architecture by Denys Serdiuk
Docker based Architecture by Denys SerdiukDocker based Architecture by Denys Serdiuk
Docker based Architecture by Denys Serdiuk
 
SparkSpark in the Big Data dark by Sergey Levandovskiy
SparkSpark in the Big Data dark by Sergey Levandovskiy  SparkSpark in the Big Data dark by Sergey Levandovskiy
SparkSpark in the Big Data dark by Sergey Levandovskiy
 
Burnout and how to avoid it in your team. Responsible person's issue by Andre...
Burnout and how to avoid it in your team. Responsible person's issue by Andre...Burnout and how to avoid it in your team. Responsible person's issue by Andre...
Burnout and how to avoid it in your team. Responsible person's issue by Andre...
 
Performance evaluation process as a way to empower your employees and help th...
Performance evaluation process as a way to empower your employees and help th...Performance evaluation process as a way to empower your employees and help th...
Performance evaluation process as a way to empower your employees and help th...
 
Selenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalks
Selenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalksSelenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalks
Selenium with py test by Alexandr Vasyliev for Lohika Odessa Python TechTalks
 
" Performance testing for Automation QA - why and how " by Andrey Kovalenko f...
" Performance testing for Automation QA - why and how " by Andrey Kovalenko f..." Performance testing for Automation QA - why and how " by Andrey Kovalenko f...
" Performance testing for Automation QA - why and how " by Andrey Kovalenko f...
 
"WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te...
"WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te..."WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te...
"WEB applications security testing" by Kirill Semenov for Lohika Odessa QA Te...
 

Último

Paper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdf
Paper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdfPaper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdf
Paper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdfNainaShrivastava14
 
Computer Graphics Introduction, Open GL, Line and Circle drawing algorithm
Computer Graphics Introduction, Open GL, Line and Circle drawing algorithmComputer Graphics Introduction, Open GL, Line and Circle drawing algorithm
Computer Graphics Introduction, Open GL, Line and Circle drawing algorithmDeepika Walanjkar
 
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork
 
Artificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewArtificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewsandhya757531
 
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMSHigh Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMSsandhya757531
 
Module-1-(Building Acoustics) Noise Control (Unit-3). pdf
Module-1-(Building Acoustics) Noise Control (Unit-3). pdfModule-1-(Building Acoustics) Noise Control (Unit-3). pdf
Module-1-(Building Acoustics) Noise Control (Unit-3). pdfManish Kumar
 
Cost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based questionCost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based questionSneha Padhiar
 
OOP concepts -in-Python programming language
OOP concepts -in-Python programming languageOOP concepts -in-Python programming language
OOP concepts -in-Python programming languageSmritiSharma901052
 
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTIONTHE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTIONjhunlian
 
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdfDEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdfAkritiPradhan2
 
Robotics Group 10 (Control Schemes) cse.pdf
Robotics Group 10  (Control Schemes) cse.pdfRobotics Group 10  (Control Schemes) cse.pdf
Robotics Group 10 (Control Schemes) cse.pdfsahilsajad201
 
CS 3251 Programming in c all unit notes pdf
CS 3251 Programming in c all unit notes pdfCS 3251 Programming in c all unit notes pdf
CS 3251 Programming in c all unit notes pdfBalamuruganV28
 
System Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingSystem Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingBootNeck1
 
Gravity concentration_MI20612MI_________
Gravity concentration_MI20612MI_________Gravity concentration_MI20612MI_________
Gravity concentration_MI20612MI_________Romil Mishra
 
『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书
『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书
『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书rnrncn29
 
11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdf11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdfHafizMudaserAhmad
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionMebane Rash
 
Research Methodology for Engineering pdf
Research Methodology for Engineering pdfResearch Methodology for Engineering pdf
Research Methodology for Engineering pdfCaalaaAbdulkerim
 
KCD Costa Rica 2024 - Nephio para parvulitos
KCD Costa Rica 2024 - Nephio para parvulitosKCD Costa Rica 2024 - Nephio para parvulitos
KCD Costa Rica 2024 - Nephio para parvulitosVictor Morales
 

Último (20)

Paper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdf
Paper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdfPaper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdf
Paper Tube : Shigeru Ban projects and Case Study of Cardboard Cathedral .pdf
 
Computer Graphics Introduction, Open GL, Line and Circle drawing algorithm
Computer Graphics Introduction, Open GL, Line and Circle drawing algorithmComputer Graphics Introduction, Open GL, Line and Circle drawing algorithm
Computer Graphics Introduction, Open GL, Line and Circle drawing algorithm
 
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
 
Artificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewArtificial Intelligence in Power System overview
Artificial Intelligence in Power System overview
 
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMSHigh Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
 
Module-1-(Building Acoustics) Noise Control (Unit-3). pdf
Module-1-(Building Acoustics) Noise Control (Unit-3). pdfModule-1-(Building Acoustics) Noise Control (Unit-3). pdf
Module-1-(Building Acoustics) Noise Control (Unit-3). pdf
 
Designing pile caps according to ACI 318-19.pptx
Designing pile caps according to ACI 318-19.pptxDesigning pile caps according to ACI 318-19.pptx
Designing pile caps according to ACI 318-19.pptx
 
Cost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based questionCost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based question
 
OOP concepts -in-Python programming language
OOP concepts -in-Python programming languageOOP concepts -in-Python programming language
OOP concepts -in-Python programming language
 
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTIONTHE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
 
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdfDEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdf
 
Robotics Group 10 (Control Schemes) cse.pdf
Robotics Group 10  (Control Schemes) cse.pdfRobotics Group 10  (Control Schemes) cse.pdf
Robotics Group 10 (Control Schemes) cse.pdf
 
CS 3251 Programming in c all unit notes pdf
CS 3251 Programming in c all unit notes pdfCS 3251 Programming in c all unit notes pdf
CS 3251 Programming in c all unit notes pdf
 
System Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingSystem Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event Scheduling
 
Gravity concentration_MI20612MI_________
Gravity concentration_MI20612MI_________Gravity concentration_MI20612MI_________
Gravity concentration_MI20612MI_________
 
『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书
『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书
『澳洲文凭』买麦考瑞大学毕业证书成绩单办理澳洲Macquarie文凭学位证书
 
11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdf11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdf
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of Action
 
Research Methodology for Engineering pdf
Research Methodology for Engineering pdfResearch Methodology for Engineering pdf
Research Methodology for Engineering pdf
 
KCD Costa Rica 2024 - Nephio para parvulitos
KCD Costa Rica 2024 - Nephio para parvulitosKCD Costa Rica 2024 - Nephio para parvulitos
KCD Costa Rica 2024 - Nephio para parvulitos
 

React native by example by Vadim Ruban

Notas del editor

  1. Работал в компании где мне удалось поучаствовать в главной роли разработчиком на React Native Поделится опытом разработки приложения на React Native
  2. Было готовое приложение под веб и десктопы Мобильное приложение похожее на скайп или другой мессенджер где упор идет на интерграцию с телефонной системой компании и CRM системами
  3. Рассмотреть Native Approach Для Android’a используется Java для iOS – Swift Вы можете использовать очень большую базу уже готовых компонентов которые работают ефективно в соответствии с гайдлайнами платформы
  4. Если разобраться не важно как ты скажешь платформе какие компоненты создавать Для Андройда - XML файл, но так же ты можешь не использовать LayoutInflater и в java коде создать новый екземпляр компонента, тоже самое для iOS Если java может сказать платформе как создать компонент то это может сделать любой язык программирования ведь практически все они быстрые В java есть JIT, но так же и в JavaScript есть JIT компилятор И если ваш код будет написан на одном языке но для каждой платформы будут создаватся разные компоненты то вы получите большое преимущество в обьеме кода для вашей бизнес логики Так же Вам не придется разбираться в деталях языка программирования для платформы На данный момент лидируют четыре технологии – и в каждой есть свои плюшки и ньюансы UX остается бытсрым потому что по факту он остается нативным
  5. Преимущество сразу видно, ты можешь сделать один интерфейс и при помощи CSS стилей изменить отображение для iOS / Android Но UX чюжеродный - пользователь заходит в приложение и сразу замечает что что то не так Честная крос—платформенная разработка Это знакомые всем технологии – не нужно разбираться в чем то новом Можно даже использовать код из веб приложения Написать hello world занимает 15 минут Когда начинал делать приложение скоуп доступных фреймворков ограничивался WebView или Native реализацией Раньше участвовал в разработке мобильного приложения под Android и гибридного приложения на WebView Преимущество сразу видно, ты можешь сделать один интерфейс и при помощи CSS стилей изменить отображение для iOS / Android Первая проблема это перформанс, кнопки не реагируют так же быстро как в других приложениях, жесты так работают по другому Если на проблемы с отзывчивастью не являются настолько важными, то в следующее во что вы упретесь – верстка веб компонентов что бы они удоретворяли гайдлайны к дизайну этой платформы
  6. It's worth noting that we're not chasing “write once, run anywhere.” Different platforms have different looks, feels, and capabilities, and as such, we should still be developing discrete apps for each platform, but the same set of engineers should be able to build applications for whatever platform they choose, without needing to learn a fundamentally different set of technologies for each. Мы ведь все знаем как строить веб-приложения, и не обязательно они проще чем тоже приложение на мобильном устройстве Но нету возможности переиспользовать эфективно этот накопленный опыт – все отличается, Checkbox > Swipe
  7. Вкратце что такое React Native React – декларативный UI в мобильном приложении! Flexbox – хорошо себя зарекомендовал в вебе, и если посмотреть на устройство лейаутов Android / iOS то они абсолютно разные, “а кто хочет заниматься изучением еще одного велосипеда” JavaScript VM сам по себе не знает как работать с сетью которая нужна для полноценной работы бизнес логики
  8. Что бы сделать Hello Worlds приложение на реакт натив достаточно написать следующий код Подход для декларации компонентов один
  9. В веб приложении что бы наш абстрактные компоненты VirtualDOM отобразить на странице нужен react-dom Библиотека которая из VDOM сделает уже валидный HTML
  10. В react-native для разных платформ используется платформо зависимый код который создаст нужный компонент именно в этой платформе
  11. React-dom как и react-native является библиотекой которая из VirtualDOM уже создает UI компоненты которые показывается на экране Рендереров на самом деле много и проблема ручных мутаций компонентов касаются не только веб приложений
  12. Что бы начать разрабатывать нужна всего одна команда для генерации проекта Не нужно заморачиваться с веб паком Сгенерирует код для Android & iOS
  13. Небольшой скрин из платформо независимых компонентов на разных платформах создает разные компоненты, с механикой и стилями этой платформы Разные шрифты Разный стиль кнопки То что ожидает пользователь
  14. - Запуск в через Xcode в режиме отладки покажет что RN создал нативные компоненты
  15. Что происходит когда пользователь запускает приложение на телефоне Что бы отобразить контент приложению нужно запустить ваш JS в виртуальной машине Главный поток (entrypoint) стартует отдельный поток с виртуальной машиной и ждет пока не будет комманд какие компоненты показать на екране Для оптимизиции поцизионирования есть отдельный прериотизированный тред для расчета позиций компонентов и другой математики JS thread не тормозит UI thread – они работают паралельно
  16. Код JavaScript запускается на JSCore поскольку эта VM уже есть в iOS из коробки Код на JavaScript не имеет доступа к памяти основного приложения, и наоборот Все общение между JS и Native сделано через мост, который сериализует/парсит в JS/Native обьекты Узкое место для скорости работы приложения, сериализация и передача данных занимает CPU
  17. Во время работы реакта будут проходить сообщения через мост к модулю из Native и параметрами компонента, тип / стили / дети
  18. Во время рендеринга / изменений VirtualDOM через мост отправляются сообщение на создание компонента, установки иерархии компонентов setChildren UIManager вызывает менеджер для типа компонента и создает новый екземпляр Для каждого Native компонента есть свой менеджер, и создавать новые менеджеры очень легко
  19. Все базовые компоненты уже доступны из коробки Select > Picker, Checkbox > Switch Есть так же компоненты которые не имеют аналогов на другой платформе
  20. Рекомендую сразу изучить какие компоненты есть из коробки и как их можно стилизировать / адаптировать для вашего дизайна
  21. Кроме компонентов RN предоставляет доступ к API платформы Добавляет полифилы для работы с сетью
  22. - Можно перенести код из веб приложения не меняя его – Сохраняется компатибилити
  23. В целом знаний достаточно что бы сделать такой скрин Но в View нету возможности указать градиент для фона
  24. Установка работает как обычный пакет NPM Если в нем есть Native код то нужно сделать react-native link
  25. Внутри используется CAGradientLayer и android.graphics.LinearGradient Что бы подключить компонент который имеет Native реализацию нужно добавить его в билд конфигурацию что бы скомпилить Зарегестрировать новый модуль что бы RN мог увидит новый функционал
  26. Для мобильных приложений очень важны анимации, когда пользователь нажимает на завершение разговора Нет ксс анимации и трансижинов, по крайней мере из коробки, но есть свой кроссплатформеный Animation API
  27. Работает паралельно render’y Использует requestAnimatinoFrame
  28. Использует requestAnimationFrame & setNativeProps минуя reconsilation Но каждый фрейм будет передаваться сообщение из JSThread в Native thread
  29. Очень часто не обязательно использовать Animated.View – можно использовать нативные компоненты для достижения результата Andriod – ViewPagerAndroid который внутри себя уже реализовывает функционал свайпа между разными вьюшками iOS я использовал ScrollView и когда пользователь завершил свайп менял offsetScroll’a который плавно через Animated API завершал перетаскивание
  30. Почти все скрины будут содержать платформо зависимые компоненты MetroBundler который собирает ваш JS под конкретную платформу, будет подключать файлы с постфиксом этой платформы в приоритете Так же используя API платформы можно определить на каком устройстве работает приложение
  31. В RN понятное дело нету функционала из коробки для аудио / видео звонков через SIP Мне нужно было написать модуль для поддержки, причем реализация в зависимости от платформы отличается
  32. Эта интеграция должна работать следующим образом Сначала JS код загружает данные сервера для SIP авторизации Передает эту информацию нативному модулю и ждет событий о новом звонке
  33. - Вызов метода из JS делается через NativeModules который имеет обьект с модулем и методами которые експортируются из Native кода
  34. В RN писать нативной код и интегрировать его с JS очень просто Предоставляет макросы для iOS кода и аннотации для JS где вызов метода из JS будет автоматом проксироватся через Bridge в натив код Просто расширить функционал благодаря двусторонней сериализации Все вызовы через RN Bridge асинхронны вы можете использовать callback’и с результатом Базовый знаний хватит для того что бы написать эту интеграцию
  35. Что бы тригерить события из натив кода есть DeviceEventEmmiter где указывается уникальное название события В JS очень просто подписатся на него, в параметрах будет уже десириализированный обьект Таким образом я добавил нужный мне API для аудио звонков
  36. Что бы тригерить события из натив кода есть DeviceEventEmmiter где указывается уникальное название события В JS очень просто подписатся на него, в параметрах будет уже десириализированный обьект Таким образом я добавил нужный мне API для аудио звонков
  37. Что бы сделать видео Библиотека PjSIP так же предоставляет платформо зависимый API для видео окна Мне нужно было сделать компонент который я смогу исопльзовать из JavaScript’a
  38. - around ~150 packages for navigation
  39. Приложение все равно остается приложением для платформы, и собственно с точки зрения упаковки придется разбираться что такое xcode ^ grandle Потратил кучу времени на баги с Xcode когда он чета кеширует не правильно и линкер не может найти одну из уже скоплированных библиотек