Answer the question
In order to leave comments, you need to log in
Explain what is happening in this section of JS code?
const _products = [....];
let shop = {
getProducts (cb) {
setTimeout(() => cb(_products), 100)
},
};
shop.getProducts(products => {
commit('setProducts', products)
})
products => {
commit('setProducts', products)
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question