store/products.js:296:
Store.setSelectedGenre
const tagList = query.tags ? query.tags.split(',') : []
const title = query.title ? query.title : ''
commit('setSelectedGenre', selectedGenre)
return await new Promise((resolve, reject) => {
if (collection.slug === SEARCH_MODE.BEST_SELLERS) {
dispatch('getOrdersWithProducts').then(() => {
try {
const products = getters.getBestSellingProductsFromOrders(
[],
node_modules/vuex/dist/vuex.common.js:853:23
Array.wrappedActionHandler
}
function registerAction (store, type, handler, local) {
var entry = store._actions[type] || (store._actions[type] = []);
entry.push(function wrappedActionHandler (payload) {
var res = handler.call(store, {
dispatch: local.dispatch,
commit: local.commit,
getters: local.getters,
state: local.state,
rootGetters: store.getters,
node_modules/vuex/dist/vuex.common.js:518:15
Store.dispatch
}
}
var result = entry.length > 1
? Promise.all(entry.map(function (handler) { return handler(payload); }))
: entry[0](payload);
return new Promise(function (resolve, reject) {
result.then(function (res) {
try {
this$1._actionSubscribers
node_modules/vuex/dist/vuex.common.js:408:21
Store.boundDispatch [as dispatch]
var store = this;
var ref = this;
var dispatch = ref.dispatch;
var commit = ref.commit;
this.dispatch = function boundDispatch (type, payload) {
return dispatch.call(store, type, payload)
};
this.commit = function boundCommit (type, payload, options) {
return commit.call(store, type, payload, options)
};
pages/collections/_slug.vue:73:
asyncData
</div>
</template>
<template v-if="products.length > 0">
<div
v-for="(slide, index) in products"
:key="`prod_${index}`"
class="v-collection-products--mobile-product"
>
<div
data-content="product-item"
@click.prevent="goToProduct(slide)"
.nuxt/utils.js:311:
promisify
data = data || {}
resolve(data)
})
})
} else {
promise = fn(context)
}
if (promise && promise instanceof Promise && typeof promise.then === 'function') {
return promise
}
.nuxt/server.js:259:
module.exports.__webpack_exports__.default
if (!Components.length) {
return render404Page()
}
// Call asyncData & fetch hooks on components matched by the route.
const asyncDatas = await Promise.all(Components.map((Component) => {
const promises = []
// Call asyncData(context)
if (Component.options.asyncData && typeof Component.options.asyncData === 'function') {
const promise = promisify(Component.options.asyncData, app.context)
node:internal/process/task_queues:96:5
processTicksAndRejections