codeburst

Bursts of code to power through your day. Web Development articles, tutorials, and news.

Follow publication

Angular State Managment — Don’t fear the boilerplate

Christian Janker
codeburst
Published in
7 min readJun 2, 2018

--

Don’t fear the boilerplate. Fear tight coupling!

Redux architecture gone wrong

Please hold on for a moment :)

1️⃣ Use Typescript

Action Interfaces
LoadCommits() ActionCreator function
Dispatch action via ngrx store
commits reducer

2️⃣ Think about Dependency Injection

3️⃣ Use selectors

Selector Service
CommitsContainer Template
Combine selectors

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Responses (7)

Write a response