Call it like this:
<api-status theme="dark" status-endpoint="/api/status"></api-status>
It uses window.fetch()
which you might have to polyfill if you haven't already: yarn add whatwg-fetch
The component expects a JSON response with a property called message
. If it's non-empty, it'll show the message.
Pretty straightforward.
Oh and if you're looking for a license: CC-Zero https://creativecommons.org/publicdomain/zero/1.0/