Store actions

Store actions (including nuxtServerInit)

// In store
{
  actions: {
    async fetchAllProducts ({ commit }) {
      const products = await this.$shopify.product.fetchAll();
      commit('SET_PRODUCTS', products)
    }
  }
}
Edit this page on GitHub Updated at Mon, Jul 3, 2023