SlideShare a Scribd company logo
1 of 10
Download to read offline
Reaktor 
Mannerheimintie 2 
00100, Helsinki Finland 
tel: +358 9 4152 0200 
www.reaktor.fi 
info@reaktor.fi 
Confidential 
©2014 Reaktor 
All rights reserved 
react + 
mobile 
Case: m.verkkokauppa.com
“low latency is a competitive 
advantage for the verkkokauppa.com 
mobile store”
single page app 
1.HTML 
2.CSS 
3.JavaScript 
4.AJAX requests 
User sees relevant content 
5.User clicks on something 
6.More AJAX requests 
Progressive 
enhancement 
1.HTML 
User sees relevant content 
2.CSS 
3.JavaScript 
4.User clicks on something 
5.AJAX requests
Traditional challenges in 
progressive enhancement 
• Which state is the DOM in as we move from backend 
to frontend? 
• The DOM rendering code is written into two different 
places 
• Rigorous testing causes loads of extra work 
• Easy to forget -> bugs in production
Solution: node.js 
Browser 
React API 
Node.js
React 101 
• Component = Mutable state + a rendering function 
• The rendering function receives the state and returns a corresponding 
DOM tree (a pure function) 
• The rendering function is run in a requestAnimationFrame loop 
• When the state changes, the DOM follows. “One way binding” 
• DOM cannot – or rather doesn’t have to – be changed by hand 
• Performance optimisation built in via Virtual DOM (no manual work!)
Progressive enhancement 
with react 
• A built-in `renderToString` function takes a React component and 
returns a corresponding HTML string. 
• The first rendition is done with renderToString and sent as the HTTP 
response body. 
• The initial state of the component is sent in the same response for use in 
the frontend. 
• When JavaScript is launched in the frontend, React takes up where the 
backend left off.
React’s solutions to challenges 
in progressive enhancement 
• The browser and the server share not only the same code, but also the 
same state. Therefore bugs related to synchronisation are categorically 
avoided. 
• No time wasted fixing bugs or writing tests. 
• Synchronisation code is restricted to one point in the codebase 
• Rest of the codebase becomes simpler. 
• The same React components are used in the backend and in the frontend. 
• Views need to be written only once
Bonuses 
• Initial load is way faster 
• Search engine and social media indexing 
for free 
• No separate tooling needed (such as 
PhantomJS, prerender.io) 
• A relatively small framework 
• Not much to learn 
• Doesn’t decide everything for you 
• Performance built in with the Virtual DOM
thanks. 
Reaktor 
Mannerheimintie 2 
00100, Helsinki Finland 
tel: +358 9 4152 0200 
www.reaktor.fi 
info@reaktor.fi 
Confidential 
©2014 Reaktor 
All rights reserved

More Related Content

What's hot

Increasing performance with Elixir Tasks
Increasing performance with Elixir TasksIncreasing performance with Elixir Tasks
Increasing performance with Elixir TasksJeffrey Chan
 
Advanced Application Architecture Symfony Live Berlin 2018
Advanced Application Architecture Symfony Live Berlin 2018Advanced Application Architecture Symfony Live Berlin 2018
Advanced Application Architecture Symfony Live Berlin 2018Matthias Noback
 
Architecture Sustaining LINE Sticker services
Architecture Sustaining LINE Sticker servicesArchitecture Sustaining LINE Sticker services
Architecture Sustaining LINE Sticker servicesLINE Corporation
 
Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...
Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...
Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...LINE Corporation
 
Akka - Developing SEDA Based Applications
Akka - Developing SEDA Based ApplicationsAkka - Developing SEDA Based Applications
Akka - Developing SEDA Based ApplicationsBenjamin Darfler
 
Windows communication foundation (part2) jaliya udagedara
Windows communication foundation (part2) jaliya udagedaraWindows communication foundation (part2) jaliya udagedara
Windows communication foundation (part2) jaliya udagedaraJaliya Udagedara
 
How to Automate Practically Anything with FME Server (Technical Webinar)
How to Automate Practically Anything with FME Server (Technical Webinar)How to Automate Practically Anything with FME Server (Technical Webinar)
How to Automate Practically Anything with FME Server (Technical Webinar)Safe Software
 
Introduction to React, Flux, and Isomorphic Apps
Introduction to React, Flux, and Isomorphic AppsIntroduction to React, Flux, and Isomorphic Apps
Introduction to React, Flux, and Isomorphic AppsFederico Torre
 
Project Dpilot Documentation
Project Dpilot DocumentationProject Dpilot Documentation
Project Dpilot DocumentationDeepAnshu Sharma
 
RubyConf Taiwan 2016 - Large scale Rails applications
RubyConf Taiwan 2016 - Large scale Rails applicationsRubyConf Taiwan 2016 - Large scale Rails applications
RubyConf Taiwan 2016 - Large scale Rails applicationsFlorian Dutey
 
Advanced application architecture
Advanced application architectureAdvanced application architecture
Advanced application architectureMatthias Noback
 
Single Page Applications: Your Browser is the OS!
Single Page Applications: Your Browser is the OS!Single Page Applications: Your Browser is the OS!
Single Page Applications: Your Browser is the OS!Jeremy Likness
 
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
 Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1... Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...WebStackAcademy
 
RubyConf China 2015 - Rails off assets pipeline
RubyConf China 2015 - Rails off assets pipelineRubyConf China 2015 - Rails off assets pipeline
RubyConf China 2015 - Rails off assets pipelineFlorian Dutey
 
Synchronizing application state using Virtual DOM trees
Synchronizing application state using Virtual DOM treesSynchronizing application state using Virtual DOM trees
Synchronizing application state using Virtual DOM treesJari Voutilainen
 
Improving end user experience using ManageEngine Applications Manager
Improving end user experience using ManageEngine Applications ManagerImproving end user experience using ManageEngine Applications Manager
Improving end user experience using ManageEngine Applications ManagerManageEngine, Zoho Corporation
 
GemStone/S @ Vienna University
GemStone/S @ Vienna University GemStone/S @ Vienna University
GemStone/S @ Vienna University ESUG
 

What's hot (20)

Increasing performance with Elixir Tasks
Increasing performance with Elixir TasksIncreasing performance with Elixir Tasks
Increasing performance with Elixir Tasks
 
Advanced Application Architecture Symfony Live Berlin 2018
Advanced Application Architecture Symfony Live Berlin 2018Advanced Application Architecture Symfony Live Berlin 2018
Advanced Application Architecture Symfony Live Berlin 2018
 
Webconnection
WebconnectionWebconnection
Webconnection
 
Architecture Sustaining LINE Sticker services
Architecture Sustaining LINE Sticker servicesArchitecture Sustaining LINE Sticker services
Architecture Sustaining LINE Sticker services
 
Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...
Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...
Building a company-wide data pipeline on Apache Kafka - engineering for 150 b...
 
Akka - Developing SEDA Based Applications
Akka - Developing SEDA Based ApplicationsAkka - Developing SEDA Based Applications
Akka - Developing SEDA Based Applications
 
Windows communication foundation (part2) jaliya udagedara
Windows communication foundation (part2) jaliya udagedaraWindows communication foundation (part2) jaliya udagedara
Windows communication foundation (part2) jaliya udagedara
 
How to Automate Practically Anything with FME Server (Technical Webinar)
How to Automate Practically Anything with FME Server (Technical Webinar)How to Automate Practically Anything with FME Server (Technical Webinar)
How to Automate Practically Anything with FME Server (Technical Webinar)
 
Introduction to React, Flux, and Isomorphic Apps
Introduction to React, Flux, and Isomorphic AppsIntroduction to React, Flux, and Isomorphic Apps
Introduction to React, Flux, and Isomorphic Apps
 
Project Dpilot Documentation
Project Dpilot DocumentationProject Dpilot Documentation
Project Dpilot Documentation
 
React Introduction
React IntroductionReact Introduction
React Introduction
 
RubyConf Taiwan 2016 - Large scale Rails applications
RubyConf Taiwan 2016 - Large scale Rails applicationsRubyConf Taiwan 2016 - Large scale Rails applications
RubyConf Taiwan 2016 - Large scale Rails applications
 
Advanced application architecture
Advanced application architectureAdvanced application architecture
Advanced application architecture
 
Single Page Applications: Your Browser is the OS!
Single Page Applications: Your Browser is the OS!Single Page Applications: Your Browser is the OS!
Single Page Applications: Your Browser is the OS!
 
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
 Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1... Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
 
RubyConf China 2015 - Rails off assets pipeline
RubyConf China 2015 - Rails off assets pipelineRubyConf China 2015 - Rails off assets pipeline
RubyConf China 2015 - Rails off assets pipeline
 
Synchronizing application state using Virtual DOM trees
Synchronizing application state using Virtual DOM treesSynchronizing application state using Virtual DOM trees
Synchronizing application state using Virtual DOM trees
 
ReactJS Code Impact
ReactJS Code ImpactReactJS Code Impact
ReactJS Code Impact
 
Improving end user experience using ManageEngine Applications Manager
Improving end user experience using ManageEngine Applications ManagerImproving end user experience using ManageEngine Applications Manager
Improving end user experience using ManageEngine Applications Manager
 
GemStone/S @ Vienna University
GemStone/S @ Vienna University GemStone/S @ Vienna University
GemStone/S @ Vienna University
 

Viewers also liked

Classical music
Classical musicClassical music
Classical musicEmilyJHinz
 
So and Mi patterns level 2
So and Mi patterns level 2So and Mi patterns level 2
So and Mi patterns level 2EmilyJHinz
 
So and Mi Patterns Level 1
So and Mi Patterns Level 1So and Mi Patterns Level 1
So and Mi Patterns Level 1EmilyJHinz
 
Changes in the Olympic Uniforms
Changes in the Olympic UniformsChanges in the Olympic Uniforms
Changes in the Olympic Uniformsnickrob445
 
20th century classical music
20th century classical music20th century classical music
20th century classical musicEmilyJHinz
 
Romantic music
Romantic musicRomantic music
Romantic musicEmilyJHinz
 
Boomwhacker songs
Boomwhacker songsBoomwhacker songs
Boomwhacker songsEmilyJHinz
 
Renaissance music
Renaissance musicRenaissance music
Renaissance musicEmilyJHinz
 
比喻 簡報 (2)
比喻  簡報 (2)比喻  簡報 (2)
比喻 簡報 (2)annaks0917
 
小師弟 Powerpoint
小師弟 Powerpoint小師弟 Powerpoint
小師弟 Powerpointannaks0917
 

Viewers also liked (13)

Rhythms
RhythmsRhythms
Rhythms
 
Classical music
Classical musicClassical music
Classical music
 
So and Mi patterns level 2
So and Mi patterns level 2So and Mi patterns level 2
So and Mi patterns level 2
 
So and Mi Patterns Level 1
So and Mi Patterns Level 1So and Mi Patterns Level 1
So and Mi Patterns Level 1
 
Changes in the Olympic Uniforms
Changes in the Olympic UniformsChanges in the Olympic Uniforms
Changes in the Olympic Uniforms
 
20th century classical music
20th century classical music20th century classical music
20th century classical music
 
Romantic music
Romantic musicRomantic music
Romantic music
 
Boomwhacker songs
Boomwhacker songsBoomwhacker songs
Boomwhacker songs
 
Baroque music
Baroque musicBaroque music
Baroque music
 
Renaissance music
Renaissance musicRenaissance music
Renaissance music
 
比喻 簡報 (2)
比喻  簡報 (2)比喻  簡報 (2)
比喻 簡報 (2)
 
小師弟 Powerpoint
小師弟 Powerpoint小師弟 Powerpoint
小師弟 Powerpoint
 
Flight night
Flight nightFlight night
Flight night
 

Similar to React + Mobile

Learning React - I
Learning React - ILearning React - I
Learning React - IMitch Chen
 
Web Development with Delphi and React - ITDevCon 2016
Web Development with Delphi and React - ITDevCon 2016Web Development with Delphi and React - ITDevCon 2016
Web Development with Delphi and React - ITDevCon 2016Marco Breveglieri
 
React for .net developers
React for .net developersReact for .net developers
React for .net developersmacsdickinson
 
Meteor Revolution: From DDP to Blaze Reactive Rendering
Meteor Revolution: From DDP to Blaze Reactive Rendering Meteor Revolution: From DDP to Blaze Reactive Rendering
Meteor Revolution: From DDP to Blaze Reactive Rendering Massimo Sgrelli
 
Introduction to React
Introduction to ReactIntroduction to React
Introduction to ReactAustin Garrod
 
Welcome to React & Flux !
Welcome to React & Flux !Welcome to React & Flux !
Welcome to React & Flux !Ritesh Kumar
 
Performance and Scalability Art of Isomorphic React Applications
Performance and Scalability Art of Isomorphic React ApplicationsPerformance and Scalability Art of Isomorphic React Applications
Performance and Scalability Art of Isomorphic React ApplicationsDenis Izmaylov
 
Code splitting with server side react
Code splitting with server side reactCode splitting with server side react
Code splitting with server side reactSaptarshi Chatterjee
 
Satisfying Business and Engineering Requirements: Client-server JavaScript, S...
Satisfying Business and Engineering Requirements: Client-server JavaScript, S...Satisfying Business and Engineering Requirements: Client-server JavaScript, S...
Satisfying Business and Engineering Requirements: Client-server JavaScript, S...Jason Strimpel
 
Reactjs notes.pptx for web development- tutorial and theory
Reactjs  notes.pptx for web development- tutorial and theoryReactjs  notes.pptx for web development- tutorial and theory
Reactjs notes.pptx for web development- tutorial and theoryjobinThomas54
 
O365 Developer Bootcamp NJ 2018 - Material
O365 Developer Bootcamp NJ 2018 - MaterialO365 Developer Bootcamp NJ 2018 - Material
O365 Developer Bootcamp NJ 2018 - MaterialThomas Daly
 
Angular Ivy- An Overview
Angular Ivy- An OverviewAngular Ivy- An Overview
Angular Ivy- An OverviewJalpesh Vadgama
 
From PHP to React - case study
From PHP to React - case studyFrom PHP to React - case study
From PHP to React - case studySparkbit
 
React Js Simplified
React Js SimplifiedReact Js Simplified
React Js SimplifiedSunil Yadav
 
Web Performance & Latest in React
Web Performance & Latest in ReactWeb Performance & Latest in React
Web Performance & Latest in ReactTalentica Software
 

Similar to React + Mobile (20)

React js
React jsReact js
React js
 
Learning React - I
Learning React - ILearning React - I
Learning React - I
 
React Tech Salon
React Tech SalonReact Tech Salon
React Tech Salon
 
Introduction to ReactJS
Introduction to ReactJSIntroduction to ReactJS
Introduction to ReactJS
 
Meteor + React
Meteor + ReactMeteor + React
Meteor + React
 
React.js at Cortex
React.js at CortexReact.js at Cortex
React.js at Cortex
 
Web Development with Delphi and React - ITDevCon 2016
Web Development with Delphi and React - ITDevCon 2016Web Development with Delphi and React - ITDevCon 2016
Web Development with Delphi and React - ITDevCon 2016
 
React for .net developers
React for .net developersReact for .net developers
React for .net developers
 
Meteor Revolution: From DDP to Blaze Reactive Rendering
Meteor Revolution: From DDP to Blaze Reactive Rendering Meteor Revolution: From DDP to Blaze Reactive Rendering
Meteor Revolution: From DDP to Blaze Reactive Rendering
 
Introduction to React
Introduction to ReactIntroduction to React
Introduction to React
 
Welcome to React & Flux !
Welcome to React & Flux !Welcome to React & Flux !
Welcome to React & Flux !
 
Performance and Scalability Art of Isomorphic React Applications
Performance and Scalability Art of Isomorphic React ApplicationsPerformance and Scalability Art of Isomorphic React Applications
Performance and Scalability Art of Isomorphic React Applications
 
Code splitting with server side react
Code splitting with server side reactCode splitting with server side react
Code splitting with server side react
 
Satisfying Business and Engineering Requirements: Client-server JavaScript, S...
Satisfying Business and Engineering Requirements: Client-server JavaScript, S...Satisfying Business and Engineering Requirements: Client-server JavaScript, S...
Satisfying Business and Engineering Requirements: Client-server JavaScript, S...
 
Reactjs notes.pptx for web development- tutorial and theory
Reactjs  notes.pptx for web development- tutorial and theoryReactjs  notes.pptx for web development- tutorial and theory
Reactjs notes.pptx for web development- tutorial and theory
 
O365 Developer Bootcamp NJ 2018 - Material
O365 Developer Bootcamp NJ 2018 - MaterialO365 Developer Bootcamp NJ 2018 - Material
O365 Developer Bootcamp NJ 2018 - Material
 
Angular Ivy- An Overview
Angular Ivy- An OverviewAngular Ivy- An Overview
Angular Ivy- An Overview
 
From PHP to React - case study
From PHP to React - case studyFrom PHP to React - case study
From PHP to React - case study
 
React Js Simplified
React Js SimplifiedReact Js Simplified
React Js Simplified
 
Web Performance & Latest in React
Web Performance & Latest in ReactWeb Performance & Latest in React
Web Performance & Latest in React
 

Recently uploaded

10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024Mind IT Systems
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerThousandEyes
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesVictorSzoltysek
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfVishalKumarJha10
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...kalichargn70th171
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsArshad QA
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...OnePlan Solutions
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplatePresentation.STUDIO
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 

Recently uploaded (20)

10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 

React + Mobile

  • 1. Reaktor Mannerheimintie 2 00100, Helsinki Finland tel: +358 9 4152 0200 www.reaktor.fi info@reaktor.fi Confidential ©2014 Reaktor All rights reserved react + mobile Case: m.verkkokauppa.com
  • 2. “low latency is a competitive advantage for the verkkokauppa.com mobile store”
  • 3. single page app 1.HTML 2.CSS 3.JavaScript 4.AJAX requests User sees relevant content 5.User clicks on something 6.More AJAX requests Progressive enhancement 1.HTML User sees relevant content 2.CSS 3.JavaScript 4.User clicks on something 5.AJAX requests
  • 4. Traditional challenges in progressive enhancement • Which state is the DOM in as we move from backend to frontend? • The DOM rendering code is written into two different places • Rigorous testing causes loads of extra work • Easy to forget -> bugs in production
  • 5. Solution: node.js Browser React API Node.js
  • 6. React 101 • Component = Mutable state + a rendering function • The rendering function receives the state and returns a corresponding DOM tree (a pure function) • The rendering function is run in a requestAnimationFrame loop • When the state changes, the DOM follows. “One way binding” • DOM cannot – or rather doesn’t have to – be changed by hand • Performance optimisation built in via Virtual DOM (no manual work!)
  • 7. Progressive enhancement with react • A built-in `renderToString` function takes a React component and returns a corresponding HTML string. • The first rendition is done with renderToString and sent as the HTTP response body. • The initial state of the component is sent in the same response for use in the frontend. • When JavaScript is launched in the frontend, React takes up where the backend left off.
  • 8. React’s solutions to challenges in progressive enhancement • The browser and the server share not only the same code, but also the same state. Therefore bugs related to synchronisation are categorically avoided. • No time wasted fixing bugs or writing tests. • Synchronisation code is restricted to one point in the codebase • Rest of the codebase becomes simpler. • The same React components are used in the backend and in the frontend. • Views need to be written only once
  • 9. Bonuses • Initial load is way faster • Search engine and social media indexing for free • No separate tooling needed (such as PhantomJS, prerender.io) • A relatively small framework • Not much to learn • Doesn’t decide everything for you • Performance built in with the Virtual DOM
  • 10. thanks. Reaktor Mannerheimintie 2 00100, Helsinki Finland tel: +358 9 4152 0200 www.reaktor.fi info@reaktor.fi Confidential ©2014 Reaktor All rights reserved