astro/examples/non-html-pages/src/pages/about.json.ts

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
272 B
TypeScript
Raw Normal View History

2022-02-25 16:28:38 +00:00
// Returns the file body for this non-HTML file.
// The content type is based off of the extension in the filename,
// in this case: about.json.
export async function get() {
return {
body: JSON.stringify({
name: 'Astro',
url: 'https://astro.build/',
}),
};
}