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
Large Scale JavaScript Application Architecture
Search
Frontend NE
February 04, 2016
Technology
1
760
Large Scale JavaScript Application Architecture
Frontend NE
February 04, 2016
Tweet
Share
More Decks by Frontend NE
See All by Frontend NE
Standardizing 'select': What the future holds for HTML - Stephanie Stimac @ FrontendNE
frontendne
4
380
CSS Regression testing - James A Lambert @ FrontendNE
frontendne
1
320
Building a design system for Lloyds Banking - Lilly Dart @ FrontendNE
frontendne
0
1.4k
What I learnt about hiring diverse teams from conducting a fully-anonymous recruitment process - Bethan Vicent
frontendne
0
260
Web Design that Doesn't Make Trans People Uncomfortable - Jessica Kelsall
frontendne
0
720
Contain yourself - Docker for developers
frontendne
2
250
Design process of a website
frontendne
0
280
What the JAMstack?
frontendne
1
890
Talking the talk
frontendne
0
470
Other Decks in Technology
See All in Technology
OpenTelemetry が拡げる Gemini CLI の可観測性
phaya72
2
890
Zephyr(RTOS)にEdge AIを組み込んでみた話
iotengineer22
0
210
[Codex Meetup Japan #1] Codex-Powered Mobile Apps Development
korodroid
2
1k
Findy Team+ QAチーム これからのチャレンジ!
findy_eventslides
0
480
ニッポンの人に知ってもらいたいGISスポット
sakaik
0
180
Oracle Base Database Service 技術詳細
oracle4engineer
PRO
12
81k
20251007: What happens when multi-agent systems become larger? (CyberAgent, Inc)
ornew
1
500
OAuthからOIDCへ ― 認可の仕組みが認証に拡張されるまで
yamatai1212
0
140
20251014_Pythonを実務で徹底的に使いこなした話
ippei0923
0
220
FinOps について (ちょっと) 本気出して考えてみた
skmkzyk
0
180
ソースを読むプロセスの例
sat
PRO
15
9.5k
All About Sansan – for New Global Engineers
sansan33
PRO
1
1.2k
Featured
See All Featured
How to train your dragon (web standard)
notwaldorf
97
6.3k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
657
61k
Rebuilding a faster, lazier Slack
samanthasiow
84
9.2k
The Art of Programming - Codeland 2020
erikaheidi
56
14k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
190
55k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
3.7k
Why Our Code Smells
bkeepers
PRO
340
57k
Automating Front-end Workflow
addyosmani
1371
200k
YesSQL, Process and Tooling at Scale
rocio
173
14k
Making Projects Easy
brettharned
120
6.4k
Docker and Python
trallard
46
3.6k
What's in a price? How to price your products and services
michaelherold
246
12k
Transcript
Large Scale JavaScript Large Scale JavaScript Application Architecture Application Architecture
ahumphreys87 ahumphreys87 JavaScript Architect at Bede Gaming. JavaScript Game Framework
that powers cross platform Bingo client and Slots games. Node.js Slots Engine, Chat Server. Node.js API facade. Core contributor to Marionette.js Issue triaging, Pull Request reviews. Bug fixing. New features!
Introduction Introduction What is a large JavaScript application? Common Pitfalls.
Useful Patterns. How frameworks apply these principles. Questions???
Over 100,000 LOC? Over Xmb in size? Lots of files?
Hard to maintain What is a Large JavaScript What is a Large JavaScript Application? Application?
"A large JavaScript application is a non-trivial application that requires
significant effort to maintain and where most of the data manipulation takes place in the browser." Addy Osmani
Modularise Modularise Break the large application up. Think of logical
components. Different sections on the screen?
4 Questions 4 Questions 1. Can I reuse my modules?
2. Will my application still function if this breaks? 3. Is it testable? 4. Does it depend on anything else?
Common Pitfalls Common Pitfalls Tight coupling. Event webs. Lack of
tests.
Tight Coupling Tight Coupling Modules depend on each other. What
happens if another module breaks? Can we reuse this module? Can you test it?
Event Webs Event Webs
Often caused by tight coupling. Modules fire events between each
other. Debugging becomes difficult. Untestable.
Loosen up! Loosen up! Loosely coupled modules. They can be
reused. They don't depend on others. They are easy to test. Create a Facade. Create a Mediator.
Facade Facade
Abstracts complexity. Exposes a simple interface. bind/trigger. Modules only communicate
with the facade.
Mediator Mediator
The "brains" of the application. Performs application specific actions based
on the events. Controls what the facade listens for. Controls what the facade sends where.
The Result The Result Modules can break without breaking the
full application. Modules can be tested independently. Modules can be reused.
How do the big guns do it? How do the
big guns do it? Backbone.Radio Services Vanilla Classes Directives Services 2 way data binding Flux Action / Dispatcher Components Components. Actions Routes / Controllers
Questions??? Questions???