Get the price of Bitcoin using the BitFinex open API

// Name: BitCoinPrice
// Description: Get latest Bitcoin price using the Bitfinex open API
// Author: Kostas Minaidis
// GitHub: @kostasx
import "@johnlindquist/kit"
let response = await get(`https://api.bitfinex.com/v1/pubticker/BTCUSD`, {
headers: {
Accept: "text/plain",
},
})
const data = response.data
await div(`
<div style="font-style:bold; padding: 1rem; font-size: 2rem;">
<p><span style="color: gray;">Price:</span> $${data.last_price}</p>
</div>
`)