Setting Up the Actions with Action Creators
Learn how to create NgRx actions with the help of action creators.
We'll cover the following...
In this lesson, we’ll configure an action to retrieve all products from the mock server.
Introduction to NgRx actions
The action represents a specific event that can occur in our application. Each action has a required type
property that identifies the type of event that occurred. For example, in the Products
component of our application, we might have an action that represents fetching data from the database. In this case, the type
property would be set to [Products] Get Products
. The convention is to write the type
property as [Module Name] Action Name
. Actions can also have an optional payload
property that contains the ...