docs(pricing): add pricing page

Add a pricing page for my paid products and services.
This commit is contained in:
Oliver Davies 2023-09-12 00:02:41 +01:00
parent d3cf57cb16
commit 615720b5fe
2 changed files with 79 additions and 0 deletions

31
src/pages/pricing.mdx Normal file
View file

@ -0,0 +1,31 @@
---
layout: ~/layouts/PageLayout.astro
title: Products and Services
---
import ListingPage from "~/components/ListingPage.astro";
import _ from "lodash";
import products from "~/products.json";
export const priceFormatter = new Intl.NumberFormat('en-GB', {
currency: 'GBP',
maximumSignificantDigits: 2,
style: 'currency',
});
<div class="space-y-6">
{products && products.map(product => (
<article class="space-y-4">
<h2>
{product.title} - {priceFormatter.format(product.price)}
{product.perMonth && (<> per month</>)}
</h2>
<div>{product.description}</div>
<footer>
<a href={product.link.href}>{product.link.text} &rarr;</a>
</footer>
</article>
))}
</div>