Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Recriando o React do Zero em 10 minutos
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Afonso Pacifer
July 29, 2023
Programming
0
100
Recriando o React do Zero em 10 minutos
Front in Sampa 2023
Afonso Pacifer
July 29, 2023
Tweet
Share
More Decks by Afonso Pacifer
See All by Afonso Pacifer
Developer Experience (DevEx) no mundo Front-End: Do Ruby ao Next.js
afonsopacifer
0
72
Open Source e Developer Experience
afonsopacifer
1
120
Conhecendo a área de Developer Experience (DevEx)
afonsopacifer
0
91
Do Zero ao Sênior Apenas com Projetos Open Source
afonsopacifer
1
95
Guia para se tornar uma Pessoa Desenvolvedora Front-end Especialista
afonsopacifer
0
88
O CAMINHO PARA SE TORNAR UM(A) MESTRE(A) DOS ESTILOS COM CSS LV 5.
afonsopacifer
0
200
HTML 5.3: O que existe além de a11y e SEO?
afonsopacifer
0
190
State of JS 2022
afonsopacifer
0
310
Welcome CSS LV5
afonsopacifer
0
240
Other Decks in Programming
See All in Programming
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
180
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
340
組織で育むオブザーバビリティ
ryota_hnk
0
160
2026年 エンジニアリング自己学習法
yumechi
0
120
re:Invent 2025 トレンドからみる製品開発への AI Agent 活用
yoskoh
0
710
AI前提で考えるiOSアプリのモダナイズ設計
yuukiw00w
0
220
ゆくKotlin くるRust
exoego
1
220
TerraformとStrands AgentsでAmazon Bedrock AgentCoreのSSO認証付きエージェントを量産しよう!
neruneruo
4
2.6k
ELYZA_Findy AI Engineering Summit登壇資料_AIコーディング時代に「ちゃんと」やること_toB LLMプロダクト開発舞台裏_20251216
elyza
2
1.3k
Automatic Grammar Agreementと Markdown Extended Attributes について
kishikawakatsumi
0
180
20260127_試行錯誤の結晶を1冊に。著者が解説 先輩データサイエンティストからの指南書 / author's_commentary_ds_instructions_guide
nash_efp
0
800
CSC307 Lecture 03
javiergs
PRO
1
480
Featured
See All Featured
Ruling the World: When Life Gets Gamed
codingconduct
0
130
Game over? The fight for quality and originality in the time of robots
wayneb77
1
91
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
53
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Raft: Consensus for Rubyists
vanstee
141
7.3k
Accessibility Awareness
sabderemane
0
45
Bash Introduction
62gerente
615
210k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.7k
Winning Ecommerce Organic Search in an AI Era - #searchnstuff2025
aleyda
0
1.8k
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.3k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
52
Transcript
afonsopacifer.github.io Recriando o React do Zero em 10 minutos 1
afonsopacifer.github.io
Afonso Pacifer @afonsopacifer afonsopacifer.github.io DevRel & Front-End Specialist 2
Como usar o React? Sem create react app ou vite!
index.js import React . from “react" import ReactDom . from
“react-dom" Inst al l $ npm install react $ npm install react-dom
const Element = React.createElement( 'h1', { className: ‘sampa' }, 'Hello
World' ); Comp on ent HelloWorld.js ?
const Element = React.createElement( … } ReactDOM.render( Element, document.getElementById(‘app’) );
<div id=”app”><div/> Hello World index.js index.html Rend e
Por que usar?
Não toca no DOM
None
None
Duas funções
.component( ) JS const Element = component( 'h1', { id:
‘sampa' }, 'Hello' ); OBJ { type: 'h1', props: { id: ‘samba' }, children: [‘Hello'] }
.render( ) JS render( OBJ, document.getElementById(‘app’) ); <h1 id=”sampa”> Hello
<h1/> DOM API Hello
Exemplo
.map( )
Não toca no DOM?
OBJ { type: 'h1', props: {id: “app”}, children: [] }
New OBJ { type: ‘h2', props: {id: “app”}, children: [] } JS component( 'h1', { id: ‘sampa' }, 'Hello' ) JS render( OBJ, document.getElementById(‘app’) ); Diff <div id=”app”><div/>
Virtual DOM
Virtual DOM DOM
None
Developer Experience
None
const Element = ( <div> <h1>Hello, world!</h1> </div> ); const
HelloWorld = () => ( <div> <Element/> </div> ); HelloWorld.js JSX
… 24
fronti n .j s fronti n .j s github.com/afonsopacifer/frontinjs $
npm install frontinjs Functional and stateless component library
fronti n .j s fronti n .j s github.com/afonsopacifer/frontinjs
27 "Não se limite a ser apenas um(a) Dev React,
seja um(a) Dev Front-End” - Afonso Pacifer
@afonsopacifer Obrigado Front in Sampa afonsopacifer.github.io 28