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
Sustainable Architectures with Angular, Monorep...
Search
Manfred Steyer
PRO
November 06, 2019
Programming
0
470
Sustainable Architectures with Angular, Monorepos and DDD @wjax 2019 in Munich
Example:
https://github.com/manfredsteyer/monorepo_domains.git
Manfred Steyer
PRO
November 06, 2019
Tweet
Share
More Decks by Manfred Steyer
See All by Manfred Steyer
Advanced Micro Frontends: Multi Version/ Framework Scenarios
manfredsteyer
PRO
0
310
Advanced Micro Frontends: Multi Version/ Framework Scenarios @WAD 2025, Berlin
manfredsteyer
PRO
0
610
Modern Angular with Signals and Signal Store:New Rules for Your Architecture @enterJS Advanced Angular Day 2025
manfredsteyer
PRO
0
480
The Missing Link in Angular‘s Signal Story Resource API and httpResource @ngRome 2025
manfredsteyer
PRO
0
160
Your Architecture as a Crime Scene:Forensic Analysis
manfredsteyer
PRO
0
220
Rethinking Data Access: The New httpResource in Angular
manfredsteyer
PRO
0
350
Reactive Thinking with Signals, Resource API, and httpResource @Devm.io Angular 20 Launch Party
manfredsteyer
PRO
0
240
JavaScript as a Crime SceneForensic Analysis
manfredsteyer
PRO
0
130
Modern Angular with Signals and Signal Store:New Rules for Your Architecture @jax2025 in Mainz, Germany
manfredsteyer
PRO
0
220
Other Decks in Programming
See All in Programming
Testing Trophyは叫ばない
toms74209200
0
530
Go言語での実装を通して学ぶLLMファインチューニングの仕組み / fukuokago22-llm-peft
monochromegane
0
110
JSONataを使ってみよう Step Functionsが楽しくなる実践テクニック #devio2025
dafujii
0
270
OSS開発者という働き方
andpad
5
1.7k
HTMLの品質ってなんだっけ? “HTMLクライテリア”の設計と実践
unachang113
3
1.8k
Jakarta EE Core Profile and Helidon - Speed, Simplicity, and AI Integration
ivargrimstad
0
320
テストカバレッジ100%を10年続けて得られた学びと品質
mottyzzz
2
450
Google I/O recap web編 大分Web祭り2025
kponda
0
2.9k
さようなら Date。 ようこそTemporal! 3年間先行利用して得られた知見の共有
8beeeaaat
1
1k
兎に角、コードレビュー
mitohato14
0
170
複雑なドメインに挑む.pdf
yukisakai1225
5
960
Trem on Rails - Prompt Engineering com Ruby
elainenaomi
1
100
Featured
See All Featured
Building an army of robots
kneath
306
46k
Build your cross-platform service in a week with App Engine
jlugia
231
18k
Raft: Consensus for Rubyists
vanstee
140
7.1k
Making the Leap to Tech Lead
cromwellryan
134
9.5k
GraphQLの誤解/rethinking-graphql
sonatard
71
11k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
36
2.5k
Building Adaptive Systems
keathley
43
2.7k
Site-Speed That Sticks
csswizardry
10
810
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
jQuery: Nuts, Bolts and Bling
dougneiner
64
7.9k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
185
54k
Transcript
@ManfredSteyer Sustainable Architectures with Angular, Monorepos and DDD ManfredSteyer Manfred
Steyer SOFTWAREarchitekt.at
@ManfredSteyer What do we need for a good architecture ?
Experience
@ManfredSteyer Domain Driven Design
@ManfredSteyer How can create sustainable frontend architectures with ideas from
DDD?
@ManfredSteyer How can create sustainable frontend architectures with ideas from
DDD?
@ManfredSteyer Contents 1) Strategic DDD in a Nutshell 2) Angular
Monorepos 3) Monorepos & DDD 4) DDD & Micro Frontends
@ManfredSteyer About me… • Manfred Steyer SOFTWAREarchitekt.at • Angular Trainings
and Consultancy • Google Developer Expert (GDE) • Trusted Collaborator in the Angular Team Page ▪ 9 Manfred Steyer Public: Frankfurt, Munich, Vienna In-House: everywhere http://softwarearchitekt.at/workshops
@ManfredSteyer 1) DDD in a nutshell
@ManfredSteyer Domain Driven Design Strategic Design Tactical Design Decomposing a
System Design Patterns & Practices
@ManfredSteyer Domain Driven Design Strategic Design Tactical Design Decomposing a
System Design Patterns & Practices
@ManfredSteyer This is what Strategic DDD prevents
@ManfredSteyer Example e-Procurement System
@ManfredSteyer Catalog Approval Specification Ordering Example Sub-Domains
@ManfredSteyer 2) Monorepos
@ManfredSteyer Workspace
@ManfredSteyer Creating a Workspace npm install -g @angular/cli ng new
workspace cd workspace ng generate app my-app ng generate lib my-lib ng serve --project my-app ng build --project my-app
@ManfredSteyer Advantages Everyone uses the latest versions No version conflicts
No burden with distributing libs Creating new libs: Adding folder Experience: Successfully used at Google, Facebook, …
@ManfredSteyer Moving back and forth Npm Registry
@ManfredSteyer Tooling & Generator https://nrwl.io/nx
@ManfredSteyer Visualize Module Structure
@ManfredSteyer Nx Monorepos and Strategic Design
@ManfredSteyer Catalog Ordering Shared Feature Feature Feature Feature Feature UI
UI UI UI UI UI UI UI UI Domain Domain Domain Domain Domain Domain Util Util Util Util Util Util Enterprise Monorepo Patterns, Nrwl 2018: https://tinyurl.com/y2jjxld7 @ManfredSteyer Shared Kernel (if really needed) & other libs Smart Comp. Dumb Comp.
@ManfredSteyer Catalog Ordering Shared Feature API Feature Feature Feature Feature
UI UI UI UI UI UI UI UI UI Domain Domain Domain Domain Domain Domain Util Util Util Util Util Util @ManfredSteyer
@ManfredSteyer Catalog Ordering Shared Feature API Feature Feature Feature Feature
UI UI UI UI UI UI UI UI UI Domain Domain Domain Domain Domain Domain Util Util Util Util Util Util @ManfredSteyer
@ManfredSteyer Application Domain Infrastructure Isolate your domain! Domain Domain Infrastructure
e. g. data access Application Use case specific facades, state management Entities, biz logic
@ManfredSteyer Alternatives to layering • e. g. Hexagonal Architecture, Clean
Architecture • Anyway: We need to restrict access b/w libraries
@ManfredSteyer DEMO
@ManfredSteyer Finegrained Libraries • Unit of recompilation • Unit of
retesting • Access restrictions • Prevent Cycles • Information Hiding • Future replacement for NgModules?
@ManfredSteyer Bonus: Facades and State Management
@ManfredSteyer Facade (Application Service) @Injectable({ providedIn: 'root' }) export class
ProductFacade { […] }
@ManfredSteyer Facade (Application Service) @Injectable({ providedIn: 'root' }) export class
ProductFacade { public products: Product[] = []; […] } State!
@ManfredSteyer Facade (Application Service) @Injectable({ providedIn: 'root' }) export class
ProductFacade { public products: Product[] = []; constructor(private productService: ProductService) { } […] }
@ManfredSteyer Facade (Application Service) @Injectable({ providedIn: 'root' }) export class
ProductsFacade { public products: Product[] = []; constructor(private productService: ProductService) { } search(category: string): void { […] } }
@ManfredSteyer Facade (Application Service) @Injectable({ providedIn: 'root' }) export class
ProductFacade { public products: Product[] = []; constructor(private productService: ProductService) { } search(category: string): void { […] } } Angular has to pull :-(
@ManfredSteyer Facade (Application Service) @Injectable({ providedIn: 'root' }) export class
ProductFacade { public products: Observable<Product[]>; constructor(private productService: ProductService) { } search(category: string): void { […] } } Also key for messaging
@ManfredSteyer App Home Catalog Search RatingFacade ProductFacade SearchFacade Facades Have
State
@ManfredSteyer App Home Catalog Search RatingFacade ProductFacade SearchFacade Facades Have
State
@ManfredSteyer App Home Catalog Search RatingFacade ProductFacade SearchFacade Facades Have
State Store (z. B. Redux/ NGRX) Observable Action
@ManfredSteyer 4) DDD and Micro Frontends? Short outlook
@ManfredSteyer Catalog Ordering Shared Feature Feature Feature Feature Feature …
… … … … … … … … @ManfredSteyer e-Procurement App Deployment Monolith
@ManfredSteyer Catalog Ordering Shared Feature Feature Feature Feature Feature …
… … … … … … … … @ManfredSteyer Catalog App Ordering App Option 1: One App per Domain
@ManfredSteyer Catalog Ordering Shared Feature Feature Feature Feature Feature …
… … … … … … … … @ManfredSteyer Catalog App Ordering App Option 2: One Monorepo per Domain Publish shared libs seperately via npm Different Versions
@ManfredSteyer Summary Slicing into sub-domains Slicing into layers Relaxed layering
Finegrained libraries Enforce restrictions Fits to micro frontends
@ManfredSteyer
@ManfredSteyer Contact and Downloads [mail]
[email protected]
[web] SOFTWAREarchitekt.at [twitter] ManfredSteyer
d Slides & Examples Public: Frankfurt, Munich, Vienna In-House: everywhere http://softwarearchitekt.at/workshops