Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

console log return from async

import axios from 'axios';

async function getItems() {
  const response = await axios.get(SOME_URL);
  console.log('done', response);
  return response;
}

getItems().then(items => console.log('items: ', items))
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #console #log #return #async
ADD COMMENT
Topic
Name
9+5 =