Example of an Action
Let's explore what Action is with the help of an example.
We'll cover the following...
What is Action?
An Action is dispatched when a message needs to be sent.
Action interface
All Actions are based on the Action interface, which defines what an Action must have. The interface is like the signature of the class. It defines what the class should have without setting the implementation. A class that implements an interface has to implement what the interface says it should have, but how the class implements that feature is up to the individual class.
The Action interface of NgRx looks like this:
interfaceAction{
...