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
昔Reactで書いたコードをHyperappに移植した話 / Porting react to...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Yuuki Sumida
September 01, 2018
Programming
290
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
昔Reactで書いたコードをHyperappに移植した話 / Porting react to hyperapp
https://gbdaitokai.connpass.com/event/94404/
Yuuki Sumida
September 01, 2018
More Decks by Yuuki Sumida
See All by Yuuki Sumida
stddev_popとstddev_sampの話 / stddev_pop and stddev_samp
razon
0
720
Monacaのビルド結果をSlackに通知したいマン[WIP] / Notify Monaca build results to Slack [WIP]
razon
0
490
ノベルティカンファレンス in 地方 / Novelty conference in local region
razon
0
890
おれたちのファイナルファンタジー勉強会 アンケート / Final Fantasy Survey
razon
1
290
フロントエンドわからなさすぎるのでVue CLIが吐き出すファイルを読む / Read the files generated by Vue CLI
razon
0
1.1k
今の飲みは次の飲みへ[完結編] / For the current drinking party to the next drinking party -final version-
razon
0
70
今の飲みは次の飲みへ / For the current drinking party to the next drinking party
razon
0
70
大都会アワード2017 / Daitokai awards 2017
razon
0
960
合体事故した話
razon
0
710
Other Decks in Programming
See All in Programming
Oxlintのカスタムルールの現況
syumai
6
1.1k
決定論的オーケストレーションの設計と実装 / Design and Implementation of Deterministic Orchestration
nrslib
3
1.3k
依存関係から依存物へ―Dependencyという言葉の歴史をひも解く
j_lee
0
120
メソッドのジェネリクスでGoの夢は広がるか? / Kyoto.go #65
utgwkk
3
730
RTSPクライアントを自作してみた話
simotin13
0
600
Hunting Vulnerabilities in Symfony with LLMs
vinceamstoutz
0
540
DynamoDBには集計系のクエリがないけどなんとかしたい
musan
1
140
Make SRE Operations Easier with Azure SRE Agent
kkamegawa
0
5.7k
ECSアプリログをFireLensでコスト削減しようとしたけど諦めた話 in Fargate×Node.js
akihisaikeda
2
4.2k
IBM Bobを活用したレガシーアプリの最新化
oniak3ibm
PRO
1
190
PHPで使える日時の表現と、その知り方 #frontend_phpcon_do
o0h
PRO
0
230
LLMによるContent Moderationの本番運用の裏側と品質担保への挑戦
suikabar
2
620
Featured
See All Featured
Ethics towards AI in product and experience design
skipperchong
2
310
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
1.4k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6k
How to audit for AI Accessibility on your Front & Back End
davetheseo
0
420
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.1k
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.1k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
201
75k
Designing Powerful Visuals for Engaging Learning
tmiket
1
410
sira's awesome portfolio website redesign presentation
elsirapls
0
280
How Software Deployment tools have changed in the past 20 years
geshan
0
34k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.5k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
380
Transcript
昔 R e a c t で 書 い た
コ ー ド を H y p e r a p p に 移 植 し た 話 合 同 勉 強 会 i n ⼤ 都 会 岡 ⼭ - 2 0 1 8 S u m m a e r - # g b d a i t o k a i
A B O U T M E Yuuki Sumida(@razon) Information
Network co.,ltd
昔 R e a c t で 書 い た
コ ー ド を H y p e r a p p に 移 植 し た 話 合 同 勉 強 会 i n ⼤ 都 会 岡 ⼭ - 2 0 1 8 S u m m a e r - # g b d a i t o k a i
React Hyperapp …今更説明するまでもないよね? https://github.com/hyperapp/hyperapp 軽量 コアは398⾏ exportされている関数はhとappのふたつのみ
import { h, app } from "hyperapp" const state =
{ count: 0 } const actions = { down: value => state => ({ count: state.count - value }), up: value => state => ({ count: state.count + value }) } const view = (state, actions) => ( <div> <h1>{state.count}</h1> <button onclick={() => actions.down(1)}>-</button> <button onclick={() => actions.up(1)}>+</button> </div> ) app(state, actions, view, document.body) State Actions View
https://kampa.me/
State
Actions
View
移植してみて(完⾛した感想) 割と楽勝だった (Viewの互換性が⾼かったおかげ?) 規模あんまり⼤きくないんだけどもういい加減直接DOM いじるのはからい、みたいなところによさそう!
カ ン パ お 願 い し ま す ま
と め 終 @razon