SlideShare a Scribd company logo
Design for Scalability
Zeeto Tech Exchange
Zeeto Tech Exchange
The Inaugural Series
• Nov – The Project / Technology Selection
• Dec – Cloud Hosting / Containers / Scheduling
• Jan – Microservices
• Feb – Design for Scalability
• Mar – Database Infrastructure
• Apr – Reporting and Analytics
• May – Lessons Learned
Our Panel This Evening
Rahmeen Shary
Director of UX
Andre Recinto
Sr. Software Engineer
Tonight’s Topic
How Pattern Libraries
and Reusable Components Future
Proof Your Application
Implementing
Reusable Components
React
• Easy to learn
● Built for creating components that we can reuse
and combine.
● Super Fast! Almost for free. Virtual DOM avoids
costly DOM operations and makes updates in a very
efficient manner.
● Well supported in the JS community.
React
And last but not least...
Netflix Facebook
Yahoo Atlassian
React Sample Code
• One Store as the Single Source of Truth.
• Built for immutable states (which can lead to better
performance in React).
• Has awesome tooling.
• Simplicity!
…in a nutshell
Redux stores your entire application state in one big,
immutable object. Whenever your application state
changes, a brand new object is created by your reducer.
"The only way to mutate the state is to emit an
action, an object describing what happened."
store.dispatch(action)
store.subscribe(listener)
store.getState()
replaceReducer(nextReducer)
Redux
And the COOLEST thing in Redux...
Redux DevTool
Redux-Form and React-Intl
Redux-Form
• A Redux reducer that listens to dispatched redux-form
actions to maintain your form state in Redux.
• A React component decorator that wraps your entire form in
a Higher Order Component (HOC) and provides
functionality via props.
• A Field component to connect your individual field inputs to
the Redux store.
• Various Action Creators for interacting with your forms
throughout the application.
React-Intl
React-Intl
• Internationalize React apps. Provides React
components and an API to format dates, numbers,
and strings including pluralization and handling
translations.
• React Intl uses and builds on the Internationalization
API built-in to JavaScript.
• React Intl's imperative API is accessed via injectIntl,
a High-Order Component (HOC).
Higher Order Component?
...a higher-order component is a function that takes
a component and returns a new component with
additional properties from itself.
const EnhancedComponent = higherOrderComponent(WrappedComponent);
React Components
Snitch
Rubeus Albus Lucius Cornelius
Snitch
The Golden Snitch, often called simply the Snitch, is the third and
smallest ball used in Quidditch. It is a walnut-sized gold-coloured sphere
with silver wings. It flies around the Quidditch field at high speeds,
sometimes pausing and hovering in place. The Seeker's goal is to catch
the Snitch before the other team's seeker, which is worth one-hundred
and fifty points. The game can only end when the Snitch has been
caught.
What is Atomic Design?
Component Breakdown
Component Breakdown
Component Breakdown
Row
Component Breakdown
Row
ColumnColumn
Component Breakdown
Row
ColumnColumn
HTML Input ElementLabel
Component Code
Form Components
Form Components

More Related Content

What's hot

Jerry Horgan - Understanding Cloud Computing
Jerry Horgan - Understanding Cloud ComputingJerry Horgan - Understanding Cloud Computing
Jerry Horgan - Understanding Cloud Computing
Bizcamp South East
 
Serverless - The Future of the Cloud?!
Serverless - The Future of the Cloud?!Serverless - The Future of the Cloud?!
Serverless - The Future of the Cloud?!
Bert Ertman
 
Computaris cloud expertise
Computaris cloud expertiseComputaris cloud expertise
Computaris cloud expertise
Computaris
 
Autoscaling near-persistent EBS
Autoscaling near-persistent EBSAutoscaling near-persistent EBS
Autoscaling near-persistent EBS
Emil Philips
 
Microservices Gone Wrong!
Microservices Gone Wrong!Microservices Gone Wrong!
Microservices Gone Wrong!
Bert Ertman
 
Using Terraform for AWS as the IaC tool
Using Terraform for AWS as the IaC toolUsing Terraform for AWS as the IaC tool
Using Terraform for AWS as the IaC tool
Lay How
 
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
Aaron Saunders
 

What's hot (7)

Jerry Horgan - Understanding Cloud Computing
Jerry Horgan - Understanding Cloud ComputingJerry Horgan - Understanding Cloud Computing
Jerry Horgan - Understanding Cloud Computing
 
Serverless - The Future of the Cloud?!
Serverless - The Future of the Cloud?!Serverless - The Future of the Cloud?!
Serverless - The Future of the Cloud?!
 
Computaris cloud expertise
Computaris cloud expertiseComputaris cloud expertise
Computaris cloud expertise
 
Autoscaling near-persistent EBS
Autoscaling near-persistent EBSAutoscaling near-persistent EBS
Autoscaling near-persistent EBS
 
Microservices Gone Wrong!
Microservices Gone Wrong!Microservices Gone Wrong!
Microservices Gone Wrong!
 
Using Terraform for AWS as the IaC tool
Using Terraform for AWS as the IaC toolUsing Terraform for AWS as the IaC tool
Using Terraform for AWS as the IaC tool
 
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
 

Similar to Zeeto Tech Exchange: Design for Scalability - Front-End

React.js at Cortex
React.js at CortexReact.js at Cortex
React.js at Cortex
Geoff Harcourt
 
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
jobinThomas54
 
An Overview of the React Ecosystem
An Overview of the React EcosystemAn Overview of the React Ecosystem
An Overview of the React Ecosystem
FITC
 
Дмитрий Тежельников «Разработка вэб-решений с использованием Asp.NET.Core и ...
Дмитрий Тежельников  «Разработка вэб-решений с использованием Asp.NET.Core и ...Дмитрий Тежельников  «Разработка вэб-решений с использованием Asp.NET.Core и ...
Дмитрий Тежельников «Разработка вэб-решений с использованием Asp.NET.Core и ...
MskDotNet Community
 
An Intense Overview of the React Ecosystem
An Intense Overview of the React EcosystemAn Intense Overview of the React Ecosystem
An Intense Overview of the React Ecosystem
Rami Sayar
 
Andrii Sliusar "Module Architecture of React-Redux Applications"
Andrii Sliusar "Module Architecture of React-Redux Applications"Andrii Sliusar "Module Architecture of React-Redux Applications"
Andrii Sliusar "Module Architecture of React-Redux Applications"
LogeekNightUkraine
 
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
Marco Breveglieri
 
Introduction to React native
Introduction to React nativeIntroduction to React native
Introduction to React native
Dhaval Barot
 
Supercharge Your SharePoint Framework Webpart with React
Supercharge Your SharePoint Framework Webpart with ReactSupercharge Your SharePoint Framework Webpart with React
Supercharge Your SharePoint Framework Webpart with React
Eric Overfield
 
An evening with React Native
An evening with React NativeAn evening with React Native
An evening with React Native
Mike Melusky
 
React state management with Redux and MobX
React state management with Redux and MobXReact state management with Redux and MobX
React state management with Redux and MobX
Darko Kukovec
 
Introduction to react native with redux
Introduction to react native with reduxIntroduction to react native with redux
Introduction to react native with redux
Mike Melusky
 
Fluxible
FluxibleFluxible
Fluxible
Taylor Lovett
 
Containers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshellContainers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshell
Eugene Fedorenko
 
Introduction to Realm Mobile Platform
Introduction to Realm Mobile PlatformIntroduction to Realm Mobile Platform
Introduction to Realm Mobile Platform
Christian Melchior
 
React js Online Training
React js Online TrainingReact js Online Training
React js Online Training
Learntek1
 
React-Js-Online-Training-9028522.ppsx
React-Js-Online-Training-9028522.ppsxReact-Js-Online-Training-9028522.ppsx
React-Js-Online-Training-9028522.ppsx
Kulbir4
 
APIs distribuidos con alta escalabilidad
APIs distribuidos con alta escalabilidadAPIs distribuidos con alta escalabilidad
APIs distribuidos con alta escalabilidad
Software Guru
 
React gsg presentation with ryan jung & elias malik
React   gsg presentation with ryan jung & elias malikReact   gsg presentation with ryan jung & elias malik
React gsg presentation with ryan jung & elias malik
Lama K Banna
 

Similar to Zeeto Tech Exchange: Design for Scalability - Front-End (20)

React.js at Cortex
React.js at CortexReact.js at Cortex
React.js at Cortex
 
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
 
An Overview of the React Ecosystem
An Overview of the React EcosystemAn Overview of the React Ecosystem
An Overview of the React Ecosystem
 
Дмитрий Тежельников «Разработка вэб-решений с использованием Asp.NET.Core и ...
Дмитрий Тежельников  «Разработка вэб-решений с использованием Asp.NET.Core и ...Дмитрий Тежельников  «Разработка вэб-решений с использованием Asp.NET.Core и ...
Дмитрий Тежельников «Разработка вэб-решений с использованием Asp.NET.Core и ...
 
An Intense Overview of the React Ecosystem
An Intense Overview of the React EcosystemAn Intense Overview of the React Ecosystem
An Intense Overview of the React Ecosystem
 
Andrii Sliusar "Module Architecture of React-Redux Applications"
Andrii Sliusar "Module Architecture of React-Redux Applications"Andrii Sliusar "Module Architecture of React-Redux Applications"
Andrii Sliusar "Module Architecture of React-Redux Applications"
 
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
 
Introduction to React native
Introduction to React nativeIntroduction to React native
Introduction to React native
 
Supercharge Your SharePoint Framework Webpart with React
Supercharge Your SharePoint Framework Webpart with ReactSupercharge Your SharePoint Framework Webpart with React
Supercharge Your SharePoint Framework Webpart with React
 
An evening with React Native
An evening with React NativeAn evening with React Native
An evening with React Native
 
React state management with Redux and MobX
React state management with Redux and MobXReact state management with Redux and MobX
React state management with Redux and MobX
 
Introduction to react native with redux
Introduction to react native with reduxIntroduction to react native with redux
Introduction to react native with redux
 
Fluxible
FluxibleFluxible
Fluxible
 
Containers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshellContainers, Serverless and Functions in a nutshell
Containers, Serverless and Functions in a nutshell
 
Introduction to Realm Mobile Platform
Introduction to Realm Mobile PlatformIntroduction to Realm Mobile Platform
Introduction to Realm Mobile Platform
 
React js Online Training
React js Online TrainingReact js Online Training
React js Online Training
 
React-Js-Online-Training-9028522.ppsx
React-Js-Online-Training-9028522.ppsxReact-Js-Online-Training-9028522.ppsx
React-Js-Online-Training-9028522.ppsx
 
SGCE 2015 REST APIs
SGCE 2015 REST APIsSGCE 2015 REST APIs
SGCE 2015 REST APIs
 
APIs distribuidos con alta escalabilidad
APIs distribuidos con alta escalabilidadAPIs distribuidos con alta escalabilidad
APIs distribuidos con alta escalabilidad
 
React gsg presentation with ryan jung & elias malik
React   gsg presentation with ryan jung & elias malikReact   gsg presentation with ryan jung & elias malik
React gsg presentation with ryan jung & elias malik
 

Recently uploaded

Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Teleport Manpower Consultant
 
Planning Of Procurement o different goods and services
Planning Of Procurement o different goods and servicesPlanning Of Procurement o different goods and services
Planning Of Procurement o different goods and services
JoytuBarua2
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
BrazilAccount1
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
Kamal Acharya
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
Jayaprasanna4
 
Runway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptxRunway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptx
SupreethSP4
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
BrazilAccount1
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
Investor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptxInvestor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptx
AmarGB2
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
obonagu
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
R&R Consult
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
TeeVichai
 
ASME IX(9) 2007 Full Version .pdf
ASME IX(9)  2007 Full Version       .pdfASME IX(9)  2007 Full Version       .pdf
ASME IX(9) 2007 Full Version .pdf
AhmedHussein950959
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
FluxPrime1
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
Kamal Acharya
 
The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
Pipe Restoration Solutions
 
space technology lecture notes on satellite
space technology lecture notes on satellitespace technology lecture notes on satellite
space technology lecture notes on satellite
ongomchris
 
Immunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary AttacksImmunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary Attacks
gerogepatton
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
Jayaprasanna4
 
ML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptxML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptx
Vijay Dialani, PhD
 

Recently uploaded (20)

Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
 
Planning Of Procurement o different goods and services
Planning Of Procurement o different goods and servicesPlanning Of Procurement o different goods and services
Planning Of Procurement o different goods and services
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
 
Runway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptxRunway Orientation Based on the Wind Rose Diagram.pptx
Runway Orientation Based on the Wind Rose Diagram.pptx
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
Investor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptxInvestor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptx
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
 
ASME IX(9) 2007 Full Version .pdf
ASME IX(9)  2007 Full Version       .pdfASME IX(9)  2007 Full Version       .pdf
ASME IX(9) 2007 Full Version .pdf
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
 
The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
 
space technology lecture notes on satellite
space technology lecture notes on satellitespace technology lecture notes on satellite
space technology lecture notes on satellite
 
Immunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary AttacksImmunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary Attacks
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
 
ML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptxML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptx
 

Zeeto Tech Exchange: Design for Scalability - Front-End

Editor's Notes

  1. Implementing Reusable Components
  2. The team chose React as the main library for our View layer. the ReactJS ecosystem is a solution built of many composable, single-purpose tools in which ReactJS is just one building block. You’re free to add only what’s needed for your application, which is good because you can build a light-weight high-performance solution that addresses exactly the issue you need to address.
  3. All the cool kids are using it. Zeeto as a company has been using React for over a year now in Production. so there is a lot of Internal experience with the toolchain, gotcha’s, and quirkyness of the library. Angular is a massive Framework as React is just the V in MVC. Angular is ● Routing ● Testing ● Structure ● Recommended Packaging ● Recommended Language ● Web API calls ● Templating ● Forms ● Style Scoping React has ● Addons ● Many react external libraries ● Easily integration with 3rd parties In contrast to AngularJS, the ReactJS ecosystem is a solution built of many composable, single-purpose tools in which ReactJS is just one building block. You’re free to add only what’s needed for your application, which is good because you can build a light-weight high-performance solution that addresses exactly the issue you need to address.
  4. Super simple. Discuss the breakdown from the pure function, and the return JSX content.
  5. Now we have the View taken care of. Next is to find a framework that will handle our controller and model. Discuss Angular and React in this pattern. React is just the View of the MVC pattern. Enter Redux.
  6. something to move towards. What is the problem? React is the View layer. We needed something to manage our state, which refers to it as the store. What is Redux? JS Framework that can manage state, subscribes to the Flux framework. Forces you to dispatch actions for all State modifications. Why? Well Supported in the community. To grasp the concepts of Redux, maybe in two days. Easy to onboard devs, 2 weeks vs 2 months. It Makes SENSE! Optional: Compare with MobX, RxJs, Flux Frameworks Better performance in Immutable states: Shallow comparison. ShouldComponentUpdate()
  7. The store can be thought of as a "middleman" for all state changes in the application. With Redux involved, components don't communicate directly between each other, but rather all state changes must go through the single source of truth, the store. This is much different from other strategies where parts of the application communicate directly between each other. Sometimes, those strategies are argued to be error prone and confusing to reason about:
  8. This means the application cannot modify the state directly. Instead, "actions" are dispatched to express an intent to change the state in the store.
  9. So as you can see, there's no method for setting state. Therefore, dispatching an action is the only way for the application code to express a state change:
  10. The dispatch() method sends an object to Redux, known as an action. The action can be described as a "payload" that carries a type and all other data that could be used to update the state — a user in this case. Keep in mind that after the type property, the design of an action object is up to you. https://css-tricks.com/learning-react-redux/ Reducers should be written as "pure" functions, a term that describes a function with the following characteristics: It does not make outside network or database calls. Its return value depends solely on the values of its parameters. Its arguments should be considered "immutable", meaning they should not be changed. Calling a pure function with the same set of arguments will always return the same value. These are called "pure" because they do nothing but return a value based on their parameters. They have no side effects into any other part of the system. It’s basically a calculation. Sort direction, settings, refreshing data, CRUD stuff.
  11. Connect allows us to subscribe to the store and also filter data we need to the component.
  12. Reducer provides default state, you have something to render. When the view renders, it dispatches an action (i.e getMembersList) When the server returns with response, a new action is dispatched and updates the store, thus updating the React View.
  13. Implementing Reusable Components
  14. Provides a connections to React and Redux Less Boilerplate code in Redux Makes it easy What is Redux-Form? More active in the community Why do we use it?
  15. Problem to solve? We need to Internationalized our app. Developed by Yahoo that connects to React that allows us internationalized and localized our strings without all the boilerplate code. Why we chose React-Intl? Other libraries: https://github.com/i18next/react-i18next
  16. These APIs are in all modern browsers (http://caniuse.com/#search=Intl) and Node.js since 0.12. It will wrap the passed-in React component with another React component which provides the imperative formatting API into the wrapped component via its props.
  17. A higher-order component (HOC) is an advanced technique in React for reusing component logic. HOCs are not part of the React API, per se. They are a pattern that emerges from React's compositional nature. You may have noticed similarities between HOCs and a pattern called container components. Container components are part of a strategy of separating responsibility between high-level and low-level concerns. Containers manage things like subscriptions and state, and pass props to components that handle things like rendering UI. HOCs use containers as part of their implementation. You can think of HOCs as parameterized container component definitions. https://facebook.github.io/react/blog/2016/07/13/mixins-considered-harmful.html
  18. Note the ...input and meta properties. Coming from redux-form
  19. How do we manage our components? Where does it live? How does the front end apps get access to the shared component library?
  20. Show Snitch and describe how it is an NPM package and how all of the front end apps bring it in as a dependency. Currently we have over several dozens of components being shared across the front end apps, from simple to the more complex components such as the nested table components, you’ll see in a bit. Once we see a similar pattern in code, we immediately make decide if this particular piece of code is good to componentize.
  21. Show Snitch and describe how it is an NPM package and how all of the front end apps bring it in as a dependency. Currently we have over several dozens of components being shared across the front end apps, from simple to the more complex components such as the nested table components, you’ll see in a bit. Once we see a similar pattern in code, we immediately make decide if this particular piece of code is good to componentize.
  22. How do we manage our components? Where does it live? How does the front end apps get access to the shared component library?
  23. So we’ll take a look at a static mockup page from Rahmeen.
  24. We’ll focus on one of the elements on the upper section of the form.
  25. We’ll zoom in to the mockup and take one of the input fields as an example to break it down.
  26. We’ll start from the main wrapper of the component, the Row Component
  27. Within the Row component, there are two Column components.
  28. Then there is the Label component and the TextInput Component
  29. How many components are reusable? It makes me smile when I see a mock up like this and I can count how many form elements with one hand.