How to use the Fetch API in JavaScript