Function to perform a fetch request and return the response data.
If the URL is not provided, the fetch fails, or the response status is not ok.
The URL to fetch.
Optional
The options for the fetch request.
The response data.
Function to perform a fetch request and return the response data.
Throws
If the URL is not provided, the fetch fails, or the response status is not ok.