SlideShare una empresa de Scribd logo
1 de 56
Descargar para leer sin conexión
O que tem de
Funcional no
React
Matheus Lima
v = f(d)
Mas pra entender
esse slide...
Precisamos
estudar a base
1. Declarativo
https://tylermcginnis.com/imperative-vs-declarative-programming
https://tylermcginnis.com/imperative-vs-declarative-programming
https://tylermcginnis.com/imperative-vs-declarative-programming
https://tylermcginnis.com/imperative-vs-declarative-programming
2. Isolamento
3. Fluxo de dados
4. Composição
https://www.youtube.com/watch?v=wfMtDGfHWpA
composição
>
herança
let === code smell
https://github.com/krasimir/react-in-patterns/tree/master/patterns/composition
https://github.com/krasimir/react-in-patterns/tree/master/patterns/composition
5. Tipos
6. Funções
Funções puras
evitar side-effects
double(x) = x * 2
double(x) = Y
f(x) = Y
f(d) = Y
f(d) = v
v = f(d)
v = f(d)
@matheusml
matheuslima.com
Centro
Av. Presidente Wilson,
231 - 29º andar
(21) 2240-2030
Cidade Monções
Av. Nações Unidas,
11.541 - 3º andar
(11) 4119-0449
Savassi
Av. Getúlio Vargas, 671
Sala 800 - 8º andar
(31) 3360-8900
www.concrete.com.br

Más contenido relacionado

Más de React Conf Brasil

Sibelius Seraphini - Relay Modern
Sibelius Seraphini - Relay ModernSibelius Seraphini - Relay Modern
Sibelius Seraphini - Relay ModernReact Conf Brasil
 
Matheus Marsiglio - Isomorphic React + Redux App
Matheus Marsiglio - Isomorphic React + Redux AppMatheus Marsiglio - Isomorphic React + Redux App
Matheus Marsiglio - Isomorphic React + Redux AppReact Conf Brasil
 
Sebastian Ferrari - Why React is good for business
Sebastian Ferrari - Why React is good for businessSebastian Ferrari - Why React is good for business
Sebastian Ferrari - Why React is good for businessReact Conf Brasil
 
Sashko Stubailo - The GraphQL and Apollo Stack: connecting everything together
Sashko Stubailo - The GraphQL and Apollo Stack: connecting everything togetherSashko Stubailo - The GraphQL and Apollo Stack: connecting everything together
Sashko Stubailo - The GraphQL and Apollo Stack: connecting everything togetherReact Conf Brasil
 
João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)
João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)
João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)React Conf Brasil
 
Raphael Amorim - Scrating React Fiber
Raphael Amorim - Scrating React FiberRaphael Amorim - Scrating React Fiber
Raphael Amorim - Scrating React FiberReact Conf Brasil
 
James Baxley - Statically typing your GraphQL app
James Baxley - Statically typing your GraphQL appJames Baxley - Statically typing your GraphQL app
James Baxley - Statically typing your GraphQL appReact Conf Brasil
 
Marcelo Camargo - Let's dive into Babel: how everything works
Marcelo Camargo - Let's dive into Babel: how everything worksMarcelo Camargo - Let's dive into Babel: how everything works
Marcelo Camargo - Let's dive into Babel: how everything worksReact Conf Brasil
 
Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...
Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...
Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...React Conf Brasil
 
Fernando Daciuk - The magic world of tests with Jest
Fernando Daciuk - The magic world of tests with JestFernando Daciuk - The magic world of tests with Jest
Fernando Daciuk - The magic world of tests with JestReact Conf Brasil
 

Más de React Conf Brasil (10)

Sibelius Seraphini - Relay Modern
Sibelius Seraphini - Relay ModernSibelius Seraphini - Relay Modern
Sibelius Seraphini - Relay Modern
 
Matheus Marsiglio - Isomorphic React + Redux App
Matheus Marsiglio - Isomorphic React + Redux AppMatheus Marsiglio - Isomorphic React + Redux App
Matheus Marsiglio - Isomorphic React + Redux App
 
Sebastian Ferrari - Why React is good for business
Sebastian Ferrari - Why React is good for businessSebastian Ferrari - Why React is good for business
Sebastian Ferrari - Why React is good for business
 
Sashko Stubailo - The GraphQL and Apollo Stack: connecting everything together
Sashko Stubailo - The GraphQL and Apollo Stack: connecting everything togetherSashko Stubailo - The GraphQL and Apollo Stack: connecting everything together
Sashko Stubailo - The GraphQL and Apollo Stack: connecting everything together
 
João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)
João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)
João Gonçalves - Show do Milhão PWA com React (Caso de Sucesso)
 
Raphael Amorim - Scrating React Fiber
Raphael Amorim - Scrating React FiberRaphael Amorim - Scrating React Fiber
Raphael Amorim - Scrating React Fiber
 
James Baxley - Statically typing your GraphQL app
James Baxley - Statically typing your GraphQL appJames Baxley - Statically typing your GraphQL app
James Baxley - Statically typing your GraphQL app
 
Marcelo Camargo - Let's dive into Babel: how everything works
Marcelo Camargo - Let's dive into Babel: how everything worksMarcelo Camargo - Let's dive into Babel: how everything works
Marcelo Camargo - Let's dive into Babel: how everything works
 
Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...
Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...
Kete Rufino e Christiano Milfont - Transformando um front-end legado em uma R...
 
Fernando Daciuk - The magic world of tests with Jest
Fernando Daciuk - The magic world of tests with JestFernando Daciuk - The magic world of tests with Jest
Fernando Daciuk - The magic world of tests with Jest