Compare commits

..
2 Commits
Author SHA1 Message Date
jfmcarreira a2f218b8de feat: add env example 2026-09-08 22:37:53 +01:00
jfmcarreira a249b32b7d fix: copy button 2026-09-01 12:13:34 +01:00
2 changed files with 8 additions and 0 deletions

No files matched your search

+1
View File
@@ -0,0 +1 @@
VITE_SITE_URL=http://localhost:5173
+7
View File
@@ -3,6 +3,13 @@ import MarkdownIt from 'markdown-it';
import { EventSchema } from './event-schema';
import type { EventData, EventMetadata } from '../types/event';
// gray-matter casts the source with Buffer.from() on every parse, and browsers have
// no Buffer, so without this the client throws before the app mounts. The result is
// only kept as an unused `orig` field, so a plain string stands in for it.
if (typeof globalThis.Buffer === 'undefined') {
(globalThis as { Buffer?: unknown }).Buffer = { from: (value: string) => value };
}
const markdown = new MarkdownIt({ html: false, linkify: true, typographer: true });
export function parseEventSource(source: string, sourceName = 'event'): EventData {