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
630
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
220
CSS Regression testing - James A Lambert @ FrontendNE
frontendne
1
200
Building a design system for Lloyds Banking - Lilly Dart @ FrontendNE
frontendne
0
940
What I learnt about hiring diverse teams from conducting a fully-anonymous recruitment process - Bethan Vicent
frontendne
0
140
Web Design that Doesn't Make Trans People Uncomfortable - Jessica Kelsall
frontendne
0
530
Contain yourself - Docker for developers
frontendne
2
160
Design process of a website
frontendne
0
140
What the JAMstack?
frontendne
1
610
Talking the talk
frontendne
0
310
Other Decks in Technology
See All in Technology
反実仮想機械学習とは何か
usaito
PRO
11
4.7k
Azureの基本的な権限管理の勉強会
yhana
0
550
Terraformあれやこれ/terraform-this-and-that
emiki
8
1.4k
DevOpsメトリクスとアウトカムの接続にトライ!開発プロセスを通して計測できるメトリクスの活用方法
ham0215
2
240
20分で完全に理解するGrafanaダッシュボード
hamadakoji
3
650
自己改善からチームを動かす! 「セルフエンジニアリングマネージャー」のすゝめ
shoota
6
730
Building Dashboards as a Hobby
egmc
0
220
エンジニアのキャリアをちょっと楽しくする3本の軸/Three Pillars to Make an Engineer's Career More Enjoyable
kwappa
0
2.7k
Cracking the KubeCon CfP
inductor
2
250
いつか使うかも貯金してたらめちゃめちゃ機能が増えてた話
riyaamemiya
0
150
JAWS-UG Bedrock Claude Night
yamahiro
3
610
生成AIの変革の時代に、直近1年で直面した課題とその解決策
ktc_wada
0
280
Featured
See All Featured
Stop Working from a Prison Cell
hatefulcrawdad
266
19k
4 Signs Your Business is Dying
shpigford
175
21k
Embracing the Ebb and Flow
colly
80
4.1k
A Philosophy of Restraint
colly
197
16k
Building Effective Engineering Teams - LeadDev
addyosmani
28
1.8k
The Invisible Side of Design
smashingmag
294
49k
Building Your Own Lightsaber
phodgson
99
5.7k
5 minutes of I Can Smell Your CMS
philhawksworth
199
19k
Into the Great Unknown - MozCon
thekraken
10
990
Learning to Love Humans: Emotional Interface Design
aarron
267
39k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
2
3.4k
How to train your dragon (web standard)
notwaldorf
73
5.2k
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???