Fetch

Repository: https://github.com/well-known-components/fetch-component

Define the component

import { createFetchComponent } from '@well-known-components/fetch-component'

export async function initComponents(): Promise<AppComponents> {
  const fetch = createFetchComponent()
  return {
    fetch
  }
}

Fetch an url

    const status = await fetch.fetch(`${url}/status`)
    await status.json()