Submit Search
Upload
Redux? 我覺得不行, 試試看 freestyle 的 Mobx
•
0 likes
•
204 views
R
reactmaker9527
Follow
Mopcon2017 交流場
Read less
Read more
Science
Report
Share
Report
Share
1 of 44
Download now
Download to read offline
Recommended
React - Reactstrap example
React - Reactstrap example
昇倫 蔡
ReactMaker - state 製作購物車範例
ReactMaker - state 製作購物車範例
昇倫 蔡
用十分鐘瞭解 《JavaScript的程式世界》
用十分鐘瞭解 《JavaScript的程式世界》
鍾誠 陳鍾誠
深度學習的機器翻譯技術 (使用node.js的neataptic套件實作)
深度學習的機器翻譯技術 (使用node.js的neataptic套件實作)
鍾誠 陳鍾誠
用十分鐘 向jserv學習作業系統設計
用十分鐘 向jserv學習作業系統設計
鍾誠 陳鍾誠
用十分鐘瞭解 陳鍾誠的程式設計課 (採用JavaScript + C的原因)
用十分鐘瞭解 陳鍾誠的程式設計課 (採用JavaScript + C的原因)
鍾誠 陳鍾誠
用十分鐘瞭解 《開放原始碼的世界》
用十分鐘瞭解 《開放原始碼的世界》
鍾誠 陳鍾誠
以 Vue / GSAP / D3 為核心的網頁視覺動態整合與架構設計 - 吳哲宇
以 Vue / GSAP / D3 為核心的網頁視覺動態整合與架構設計 - 吳哲宇
哲宇 吳
Recommended
React - Reactstrap example
React - Reactstrap example
昇倫 蔡
ReactMaker - state 製作購物車範例
ReactMaker - state 製作購物車範例
昇倫 蔡
用十分鐘瞭解 《JavaScript的程式世界》
用十分鐘瞭解 《JavaScript的程式世界》
鍾誠 陳鍾誠
深度學習的機器翻譯技術 (使用node.js的neataptic套件實作)
深度學習的機器翻譯技術 (使用node.js的neataptic套件實作)
鍾誠 陳鍾誠
用十分鐘 向jserv學習作業系統設計
用十分鐘 向jserv學習作業系統設計
鍾誠 陳鍾誠
用十分鐘瞭解 陳鍾誠的程式設計課 (採用JavaScript + C的原因)
用十分鐘瞭解 陳鍾誠的程式設計課 (採用JavaScript + C的原因)
鍾誠 陳鍾誠
用十分鐘瞭解 《開放原始碼的世界》
用十分鐘瞭解 《開放原始碼的世界》
鍾誠 陳鍾誠
以 Vue / GSAP / D3 為核心的網頁視覺動態整合與架構設計 - 吳哲宇
以 Vue / GSAP / D3 為核心的網頁視覺動態整合與架構設計 - 吳哲宇
哲宇 吳
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
Skeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
Introduction to Data Science
Introduction to Data Science
Christy Abraham Joy
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
Vit Horky
The six step guide to practical project management
The six step guide to practical project management
MindGenius
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
More Related Content
Featured
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
Skeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
Introduction to Data Science
Introduction to Data Science
Christy Abraham Joy
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
Vit Horky
The six step guide to practical project management
The six step guide to practical project management
MindGenius
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
Featured
(20)
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
Skeleton Culture Code
Skeleton Culture Code
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
How to have difficult conversations
How to have difficult conversations
Introduction to Data Science
Introduction to Data Science
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
The six step guide to practical project management
The six step guide to practical project management
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Redux? 我覺得不行, 試試看 freestyle 的 Mobx
1.
Redux? 我覺得不⾏行行, 試試看 freestyle
的 Mobx
2.
先問問看⼤大家來來⾃自哪個陣營
3.
關於 ReactMaker
4.
Hyman 前端⼯工程師,喜歡研究新的技術,也喜 歡研究有趣的UI跟效果,想要帶領更更多 的⼈人進入ReactJS的世界,最近在研究 Mobx.js! Andy ⼀一頭栽進前端世界的⼩小⼩小⼯工程師,喜歡 玩各種前端新鮮事物。 ⽬目前專注於 ReactJS,使⽤用過Flux、Redux、Mobx 等單向資料流進⾏行行專案開發。 Giant 在團隊中擔任聯聯絡窗⼝口,⽬目前是⾼高應⼤大 碩⽣生,由於對前端開發有興趣,因此就 跟⼤大⼤大們⼀一起組成讀書會,專注於學習 ReactJs。 簡單介紹⼀一下成員
5.
故事是這樣的
6.
剛開始學習React的我
7.
⼀一週後
8.
Why?
9.
ReactJS 特⾊色之⼀一 元件化 海海⾨門
Hyman ⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人 <User name="海海⾨門 Hyman" desc="⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人" src="profile.png" />
10.
海海⾨門 Hyman ⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人 迪倫倫 Andy 當⼿手上只有鎚⼦子,看到的東⻄西都是... 及米
Jimmy 信念念、毅⼒力力、勇氣三者具備 ⼩小森 Winsome 互相瞭解是朋友,互相理理解是知⼰己 x 元件化可以幫助我們 不⽤用複製貼上
11.
加上Virtual DOM,我只要改資料就可以⾺馬上渲染 海海⾨門 Hyman ⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人 迪倫倫
Andy ⼈人永遠在追求快活,永遠在逃避痛苦 及米 Jimmy 信念念、毅⼒力力、勇氣三者具備 ⼩小森 Winsome 互相瞭解是朋友,互相理理解是知⼰己 x { name: '海海⾨門 Hyman', desc: '⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人' } 海海綿 Hyman ⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人 { name: '海海綿 Hyman', desc: '⽤用愛⼼心來來做事,⽤用感恩的⼼心做⼈人' }
12.
React元件樹資料可以共享
13.
但是不同的元件樹要共享資料有困難 ??
14.
後來來我找到了了Redux來來解 決這個問題
15.
16.
透過connect把Store的資料 注入到props 裡⾯面
17.
剛開始學習Redux的我
18.
⼀一週後
19.
Why?
20.
事情是這樣的,我想做⼀一個簡單的系統, ⼤大概就是 todolist 那樣的難度
21.
然後就開始研究了了Redux資料流
22.
23.
恩....的確是很好的設計
24.
25.
等等...好像在哪裡看過
26.
27.
action - 聖旨
28.
action creator -
內閣
29.
store - 太監總管
30.
reducer - 宣旨的太監
31.
皇上下旨 (Button Click Event) 內閣 (action
creator) 產⽣生聖旨 (action) 太監總管派發 (store) ⼩小太監宣旨 (reducer)
32.
後來來我找到Mobx
33.
我們先來來看⼀一下Mobx資料流
34.
皇上下旨 (Button Click Event) 內閣 (action
creator) 產⽣生聖旨 (action) 太監總管派發 (store) ⼩小太監宣旨 (reducer)
35.
36.
邏輯層⾯面 Redux Mobx store, view,
action 整個單向資料流 專注於store, view
37.
狀狀態更更新 Redux Mobx 狀狀態更更新必須是Immutable 沒有特別要求
38.
Middleware Redux Mobx 有很多Middleware (redux-thunk, redux-saga) 沒有Middleware 但是
mobs 有 mobx-util 可以轉換成 rxjs
39.
Extension Redux Mobx 有很多 也有很多 https://github.com/mobxjs/awesome-mobx#related-projects-and-utilities
40.
41.
總結 Redux Mobx 學習曲線較陡 結構較嚴謹 適合⼤大型專案 學習曲線平緩 較有彈性 適合中⼩小型專案
42.
QA Time
43.
懇請按讚 FB:ReactMaker GH:ReactMaker
44.
• https://segmentfault.com/a/1190000004257207 • http://renzhou.tw/yinwubrother-textmaker/ •
https://noootown.gitbooks.io/deeperience-react-native-boilerplate/ content/Redux/Redux%20&%20React.html • https://www.kirupa.com/react/transferring_properties.htm • https://twitter.com/mweststrate/status/718444275239882753 參參考連結
Download now