最佳答案
fetch() {
return axios.get('/rest/foo')
//.then(response => {throw new Error(response)}) // Uncomment to test network error
//.then( <<add delay here>> ) // Uncomment to simulate network delay
}
How do I add delay in the latter then block, so it will wait specified amount of time before passing control to the fetch callers then blocks?