Marko Stanimirović
NgRx Tips for Future-Proof Angular Apps
#1about 4 minutes
Consolidate global state into a single NgRx store
Avoid splitting global state between NgRx and stateful services to improve reusability and reduce component dependencies.
#2about 2 minutes
Use selectors to compute derived state on demand
Calculate derived data using memoized selectors instead of storing it in the state to simplify reducers and reduce state size.
#3about 2 minutes
Simplify components with view model selectors
Combine multiple state slices into a single view model selector to simplify component logic and template bindings.
#4about 1 minute
Create reusable and maintainable case reducers
Handle multiple actions in a single case reducer for shared logic, but split them into separate reducers when state changes diverge.
#5about 4 minutes
Treat actions as unique events, not commands
Use the source-event pattern to name actions descriptively, avoiding sequential dispatches and improving application traceability.
#6about 2 minutes
Organize actions by grouping them by source
Structure your codebase by creating dedicated action files for each source, such as pages, APIs, or guards.
#7about 1 minute
Name NgRx effects based on their function
Name effects based on the task they perform rather than the action they listen to, improving readability and maintainability.
#8about 2 minutes
Keep effects simple by moving logic to services
Isolate complex business logic within services and call them from effects to keep the effects simple, readable, and easy to test.
#9about 1 minute
Avoid creating unnecessary boilerplate effects
Eliminate intermediate effects by having the primary effect listen to multiple source actions directly, reducing boilerplate code.
#10about 2 minutes
Apply good action hygiene within NgRx effects
Return a single unique event with a complete data payload from an effect instead of an array of command actions to decouple state updates.
#11about 3 minutes
Adopting NgRx best practices for future-proof apps
Following established best practices for NgRx store and effects improves code quality, maintainability, and performance in large Angular applications.
Related jobs
Jobs that call for the skills explored in this talk.
MARKT-PILOT GmbH
Stuttgart, Germany
Remote
€75-90K
Senior
Java
TypeScript
+1
Matching moments
03:16 MIN
Improving the developer feedback loop with specialized tools
Developer Time Is Valuable - Use the Right Tools - Kilian Valkhof
02:33 MIN
Why you might not need JavaScript for everything
WeAreDevelopers LIVE – You Don’t Need JavaScript, Modern CSS and More
03:31 MIN
The value of progressive enhancement and semantic HTML
WeAreDevelopers LIVE – You Don’t Need JavaScript, Modern CSS and More
11:32 MIN
The industry's focus on frameworks over web fundamentals
WeAreDevelopers LIVE – Frontend Inspirations, Web Standards and more
11:10 MIN
The only frontend stack that truly matters
WeAreDevelopers LIVE – Frontend Inspirations, Web Standards and more
09:00 MIN
Navigating the growing complexity of modern CSS
WeAreDevelopers LIVE – You Don’t Need JavaScript, Modern CSS and More
08:07 MIN
Exploring modern JavaScript performance and new CSS features
WeAreDevelopers LIVE – AI, Freelancing, Keeping Up with Tech and More
07:46 MIN
The challenge of keeping up with modern CSS
WeAreDevelopers LIVE – AI, Freelancing, Keeping Up with Tech and More
Featured Partners
Related Videos
Angular tips/tricks you can use from tomorrow on
Benedikt Starzengruber
Hello generics, goodbye boilerplate!
Miroslav Jonaš
Practice makes perfect - when it comes to RxJS
Jan-Niklas Wortmann
Client-Side State Management Reimagined – Think Outside the Box
Michael Egger-Zikes
Angular Signals: what's all the fuss about?
Daniela Bonvini
Sustainable Angular Architectures with Nx and Strategic Design
Manfred Steyer
Angular Unleashed: Mastering Modern Web Development with Angular
Indu Chaube
How to Create New RxJS Operators
Mohammad-Ali A'râbi
Related Articles
View all articles



From learning to earning
Jobs that call for the skills explored in this talk.


Visonum GmbH
Remote
Junior
Intermediate
React
Redux
TypeScript

Confideck GmbH
Vienna, Austria
Remote
Intermediate
Senior
Node.js
MongoDB
TypeScript

Adaptive Financial Consulting
Barcelona, Spain
CSS
HTML
RxJS
React
JavaScript
+1


Nexus
Charing Cross, United Kingdom
Docker
Node.js
Jasmine
JavaScript
Kubernetes
+6

Oxigent Technologies
Barcelona, Spain
€40K
Senior
React
TypeScript

Rxswift
Municipality of Las Rozas de Madrid, Spain
Remote
€40-60K
iOS
Core Data
Objective-C
+3

Nexthink
Municipality of Madrid, Spain
Remote
CSS
HTML
React
Next.js
+4