Core Concepts: Actions
Learn about Vuex actions and how they can benefit our Vue apps.
We'll cover the following...
Vuex actions allow us to perform complex logic within the state machine. For example, we can use Vuex actions to centralize API communication, do checks, and trigger other actions. Actions can trigger further actions, one or more mutations, or both. Some apps have established the convention that mutations must be triggered by actions only and may not be triggered by a component directly.
How to define actions
To define Vuex actions, we add them as functions in a nested object inside the ...