Experiences building apps with React Native @DomCode 2016

30
REACT NATIVE DomCode, November 2016, Adrian Philipp

Transcript of Experiences building apps with React Native @DomCode 2016

Page 1: Experiences building apps with React Native @DomCode 2016

REACT NATIVEDomCode, November 2016, Adrian Philipp

Page 2: Experiences building apps with React Native @DomCode 2016

1. Web developers can make apps

2. Know and use tooling to be more productive

3. Learn platform concepts and dev tricks

REACT NATIVE

Page 4: Experiences building apps with React Native @DomCode 2016

QAPP Question and Answer iOS app - beta

Developed at

Page 5: Experiences building apps with React Native @DomCode 2016

• Made by Facebook, efficiency across platforms

• “Learn once, write anywhere” vs “cross platform”

• Platforms: iOS, Android, Windows, macOS, tvOS

• High traction: 39.8k stars, releases every 2-3 weeks

• Not mature yet

REACT NATIVE

Page 6: Experiences building apps with React Native @DomCode 2016

UI Explorer React Native Example See README on github how to build

and run the app

Page 7: Experiences building apps with React Native @DomCode 2016

• Easy way for web developers to get started on mobile

REACT NATIVE

Page 8: Experiences building apps with React Native @DomCode 2016

• Easy way for web developers to get started on mobile

• Styling is similar to CSS

REACT NATIVE

Page 9: Experiences building apps with React Native @DomCode 2016

• Easy way for web developers to get started on mobile

• Styling is similar to CSS

• Flexbox layout model

REACT NATIVE

Page 10: Experiences building apps with React Native @DomCode 2016

• Easy way for web developers to get started on mobile

• Styling is similar to CSS

• Flexbox layout model

• Feels like React (web)

REACT NATIVE

Page 11: Experiences building apps with React Native @DomCode 2016

Product PainsBut production ready

NOT MATURE

Page 12: Experiences building apps with React Native @DomCode 2016

Show me code…

hackernews search app made by algolia

REACT NATIVE

Page 13: Experiences building apps with React Native @DomCode 2016

BASICS

Page 14: Experiences building apps with React Native @DomCode 2016

CODE

Page 15: Experiences building apps with React Native @DomCode 2016

APP

Page 16: Experiences building apps with React Native @DomCode 2016

CODE

Page 17: Experiences building apps with React Native @DomCode 2016

1. Web developers can make apps

2. Know and use tooling to be more productive

3. Learn platform concepts and dev tricks

REACT NATIVE

Page 18: Experiences building apps with React Native @DomCode 2016

• Inspector

• Hot reloading

• Profiling using systrace

• Debugger

• Editor integration

TOOLING

Page 19: Experiences building apps with React Native @DomCode 2016

INSPECTOR

Page 20: Experiences building apps with React Native @DomCode 2016

HOT RELOADING

Page 21: Experiences building apps with React Native @DomCode 2016

PROFILING

Page 22: Experiences building apps with React Native @DomCode 2016

DEBUGGER

Page 23: Experiences building apps with React Native @DomCode 2016

EDITOR INTEGRATION

• WebStorm/PHPStorm: JS/JSX/ES6 support

• Microsoft VSCode, Nuclide

• Clickable stack trace:REACT_EDITOR=pstorm npm start

Page 24: Experiences building apps with React Native @DomCode 2016

EDITOR INTEGRATION

Page 25: Experiences building apps with React Native @DomCode 2016

ANDROID

Page 26: Experiences building apps with React Native @DomCode 2016

1. Web developers can make apps

2. Know and use tooling to be more productive

3. Learn platform concepts and dev tricks

REACT NATIVE

Page 27: Experiences building apps with React Native @DomCode 2016

• Learn how mobile platforms work and look

• Split smart and dumb components from the start

• Use redux when the app gets more complex

PLATFORM / ARCHITECTURE

Page 28: Experiences building apps with React Native @DomCode 2016

• Components: JS.coach

• React Native Playground rnplay

• ESLint style from airbnb

• NPM script to build "build-ios": "react-native bundle --platform=ios --entry-file=index.ios.js --bundle-output=ios/main.jsbundle --assets-dest=ios/assets --dev false",

DEV TRICKS

Page 29: Experiences building apps with React Native @DomCode 2016

1. Web developers can make apps

2. Know and use tooling to be more productive

3. Learn platform concepts and dev tricks

REACT NATIVE

Page 30: Experiences building apps with React Native @DomCode 2016

Twitter: @adrian_philipp

Github: adri

Website: adrian-philipp.com

Mail: [email protected]

Joind.in: https://legacy.joind.in/19687

THANK YOU