Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
react best practice
Search
yiminghe
May 14, 2015
Technology
3
220
react best practice
react best practice
yiminghe
May 14, 2015
Tweet
Share
More Decks by yiminghe
See All by yiminghe
小程序终端技术架构
yiminghe
0
240
支付宝小程序的开放架构
yiminghe
0
190
gitc2016 react based architecture
yiminghe
1
170
antd at qcon2016
yiminghe
1
230
react-based architecture
yiminghe
2
160
React Ecosystem At Ant Financial
yiminghe
4
2.3k
ant design preview
yiminghe
1
310
react at alipay
yiminghe
43
4.4k
form validation in react
yiminghe
4
560
Other Decks in Technology
See All in Technology
ESXi のAIOps だ!2025冬
unnowataru
0
180
AWS re:Invent 2025 re:Cap LT大会 データベース好きが語る re:Invent 2025 データベースアップデート/セッションの紹介
coldairflow
0
140
2025-12-18_AI駆動開発推進プロジェクト運営について / AIDD-Promotion project management
yayoi_dd
0
150
ExpoのインダストリーブースでみたAWSが見せる製造業の未来
hamadakoji
0
180
SREには開発組織全体で向き合う
koh_naga
0
410
モダンデータスタックの理想と現実の間で~1.3億人Vポイントデータ基盤の現在地とこれから~
taromatsui_cccmkhd
1
220
たまに起きる外部サービスの障害に備えたり備えなかったりする話
egmc
0
360
AI with TiDD
shiraji
1
150
MySQLとPostgreSQLのコレーション / Collation of MySQL and PostgreSQL
tmtms
1
1.1k
20251222_サンフランシスコサバイバル術
ponponmikankan
2
130
Microsoft Agent 365 についてゆっくりじっくり理解する!
skmkzyk
0
440
Oracle Database@Azure:サービス概要のご紹介
oracle4engineer
PRO
2
170
Featured
See All Featured
Music & Morning Musume
bryan
46
7k
What does AI have to do with Human Rights?
axbom
PRO
0
1.9k
Darren the Foodie - Storyboard
khoart
PRO
0
1.9k
The Invisible Side of Design
smashingmag
302
51k
Embracing the Ebb and Flow
colly
88
4.9k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
170
Odyssey Design
rkendrick25
PRO
0
430
Getting science done with accelerated Python computing platforms
jacobtomlinson
0
76
Information Architects: The Missing Link in Design Systems
soysaucechin
0
710
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
320
Optimising Largest Contentful Paint
csswizardry
37
3.5k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
0
110
Transcript
react best prac*ce
[email protected]
承玉
Outline • Technology stack – react/koa/webpack/npm • Prac*ce
• Summary
• Technology stack
react • react: library for build user interface
react • render
react • diff
React-‐components • Components based on react • hDps://github.com/react-‐component
react-‐component
koa • Koa: next genera*on web framework for node.js
chain
chair • 基于 koa,整合支付宝基础服务 – Session – Hsf(Tr) – Drm
– Tair – Ls
chair • Router • logger • Proxy (generate
from jar)
webpack • hDp://webpack.github.io/ • Module bundler
npm • Package manager for javascript (react,jquery,angular…)
tnpm • 集团内部源,支持私有包
• prac*ce
tnpm • package.json:
commonjs • commonjs for browser and server
react • Components Composi*on
Custom page • aliloan
React rerender • Render on data change
webpack • commonjs compile, sourcemap • Common code extrac*on
• Css extrac*on
webpack • Development – Build into memory – koa middleware
– No hash
webpack • Build – Compress – hash
jsx on server • jsx as skeleton on server
share code with server • u*l/enum/jsx … • app/common/getUserFromIvr.js:
dev.assets • Half dead – Serve sta*c resources in nodejs
memory (webpack) – Speedy cbd cycle
summary • server-‐browser harmony – js rules all – Use
React on server and browser – Use npm on server and browser – Use webpack on server and browser