fetch() { return axios.get('/rest/foo') .then(value => new Promise(resolve => { setTimeout(() => { resolve(value); }, delayInMilliseconds); }) ); }