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
Optimizing Contents Delivery
Search
Gen
March 24, 2017
Programming
0
29
Optimizing Contents Delivery
Gen
March 24, 2017
Tweet
Share
More Decks by Gen
See All by Gen
VRT
gen
0
12
Introduction to WebRTC
gen
0
230
Introduction to ECS
gen
0
40
Introduction to multiplayer netcode
gen
0
77
Introduction to WebGL
gen
0
51
部屋のワイシャツとカメラと私
gen
0
410
Interaction designer のお仕事
gen
0
83
Other Decks in Programming
See All in Programming
16年目のピクシブ百科事典を支える最新の技術基盤 / The Modern Tech Stack Powering Pixiv Encyclopedia in its 16th Year
ahuglajbclajep
5
990
Fluid Templating in TYPO3 14
s2b
0
130
今から始めるClaude Code超入門
448jp
7
8.5k
組織で育むオブザーバビリティ
ryota_hnk
0
170
Oxlint JS plugins
kazupon
1
740
ぼくの開発環境2026
yuzneri
0
100
AIで開発はどれくらい加速したのか?AIエージェントによるコード生成を、現場の評価と研究開発の評価の両面からdeep diveしてみる
daisuketakeda
1
970
CSC307 Lecture 08
javiergs
PRO
0
670
高速開発のためのコード整理術
sutetotanuki
1
390
FOSDEM 2026: STUNMESH-go: Building P2P WireGuard Mesh Without Self-Hosted Infrastructure
tjjh89017
0
150
疑似コードによるプロンプト記述、どのくらい正確に実行される?
kokuyouwind
0
380
Grafana:建立系統全知視角的捷徑
blueswen
0
330
Featured
See All Featured
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
1
1.4k
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
61
52k
Evolving SEO for Evolving Search Engines
ryanjones
0
120
How to audit for AI Accessibility on your Front & Back End
davetheseo
0
180
Why You Should Never Use an ORM
jnunemaker
PRO
61
9.7k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
141
34k
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
1
49
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
140
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
659
61k
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
The browser strikes back
jonoalderson
0
360
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Transcript
Optimizing Contents Delivery Gen Ichino<@zenoplex>
໔ࣄ߲ (͍͍Θ͚λΠϜ) • FP, FRP ͷ͠·ͤΜ • Rx ͷ͠·ͤΜ •
τʔΫεΫϦϓτ࿅श͍ͯ͠ͳ͍Ͱ͢ • 2018 ʹ͋ͨΓલʹͳΔ͔͠Εͳ͍
“Mobile First” FTW http://gs.statcounter.com/press/mobile-and-tablet-internet-usage-exceeds- desktop-for- fi rst-time-worldwide
Code splitting
Why?
bundle.js
bundle.js vendor.js
Long-term caching • มߋ͕΄ͱΜͲೖΒͳ͍Ϟδϡʔϧ܈ • bundle໊ʹhashΛ͏ • max-age: 31536000 (RFC
2616) • CDN
vendor.js Home Settings User menu button Login
How?
es6 Dynamic Import // sync import React from 'react'; //
sync import { Component } from 'react'; // async const AsyncModulePromise = import('../some_modules');
import() • babel-plugin: syntax-dynamic-import • Stage 3 • Webpack 2
• (path: string) => Promise<*> • Support dynamic module name
DEMO https://syntax-dynamic-import-sample.herokuapp.com/
Webpack
React
React Components • Functions • Classes • Promises
DEMO https://syntax-dynamic-import-react-sa.herokuapp.com/
Where?
Where to code split • Route level • High Order
Components
DEMO https://syntax-dynamic-import-react-sa.herokuapp.com/about
Overhead • Heroku still only supports HTTP/1.1 • Overuse can
lead to less user experience
Is JavaScript mobile friendly?
Responsive Component • Mobile First JavaScript • Always render Mobile
Components • Lazy load Desktop Components when and only if necessary
Thx