((resolve) => {
+ const key = projectKey();
+ if (key === null || typeof window === 'undefined') return resolve(null);
+ afterLoad(() => {
+ import('posthog-js')
+ .then(({ default: posthog }) => {
+ posthog.init(key, buildConfig());
+ resolve(posthog);
+ })
+ .catch(() => resolve(null));
+ });
+ });
+ return loading;
+}
+
+/** Sends one event. Never throws, and never waits for anything the page needs. */
+export function capture(event: AnalyticsEvent): void {
+ if (projectKey() === null) return;
+ void load().then((client) => {
+ try {
+ client?.capture(event.name, event.props);
+ } catch {
+ // Analytics must never break a page.
+ }
+ });
+}
diff --git a/lib/privacy-text.test.tsx b/lib/privacy-text.test.tsx
new file mode 100644
index 0000000..52a1940
--- /dev/null
+++ b/lib/privacy-text.test.tsx
@@ -0,0 +1,74 @@
+import { renderToStaticMarkup } from 'react-dom/server';
+import { describe, expect, it, vi } from 'vitest';
+
+// The privacy page's footer is a client component of the design package; the
+// words under test are the page's own.
+vi.mock('@/components/alpha/SiteFooter', () => ({ SiteFooter: () => null }));
+
+const { default: PrivacyPage } = await import('@/app/(site)/privacy/page');
+
+// The owner's approved wording, character for character (reports/texts-for-approval.md,
+// items 1a, 1b and 1c). A later edit to any of it fails here and needs the owner.
+const COUNTING_VISITS =
+ 'Counting visits. To learn how many people read this site and whether the form works, each page you open sends one short message to a measurement service. It says which page was opened (the home page, this page, the confirmation page, or another) and carries what your browser sends with any request, such as its name and version. When you send the form, a second message says whether it worked or failed, and never the address you entered. Nothing is stored in your browser for this. The messages of one visit share a random number that lasts only while the page is open, so there is no identifier that lasts beyond the page, and nothing links one visit to the next. The service does not receive your network address; it sees only that of the provider that hosts this site, and works out no location.';
+const PROCESSOR_CLAUSE =
+ 'a measurement service in the European Union, which receives the messages described under "Counting visits" through this site\'s own address;';
+const COOKIES =
+ 'Cookies. This site sets no advertising or analytics cookies. Your browser keeps a few settings for it, such as the appearance you choose.';
+
+// The page's visible text, one string per paragraph, tags and entities gone.
+function paragraphs(): string[] {
+ const html = renderToStaticMarkup();
+ return [...html.matchAll(/]*>([\s\S]*?)<\/p>/g)].map(([, inner]) =>
+ inner
+ .replace(/<[^>]+>/g, '')
+ .replace(/"/g, '"')
+ .replace(/'|'|'/g, "'")
+ .replace(/&/g, '&')
+ .replace(/\s+/g, ' ')
+ .trim(),
+ );
+}
+
+describe('the privacy page, counting visits', () => {
+ it('carries the approved paragraph, whole, directly after "Where you signed up from"', () => {
+ const all = paragraphs();
+ const at = all.findIndex((p) => p.startsWith('Where you signed up from.'));
+ expect(at).toBeGreaterThanOrEqual(0);
+ expect(all[at + 1]).toBe(COUNTING_VISITS);
+ expect(all[at + 2]).toMatch(/^Who holds it\./);
+ });
+
+ it('names the measurement service among the processors, after the host and before the spam check', () => {
+ const handled = paragraphs().find((p) => p.startsWith('Who else handles it.')) ?? '';
+ expect(handled).toContain(`the provider that hosts this site; ${PROCESSOR_CLAUSE} and a spam-check service`);
+ });
+
+ // The owner's approved basis sentence, and the changed last sentence, with
+ // everything else in the paragraph as it was.
+ it('states the basis for counting, and lets the reader object to any of the three', () => {
+ const why = paragraphs().find((p) => p.startsWith('Why we may hold it.')) ?? '';
+ expect(why).toBe(
+ 'Why we may hold it. For the waitlist and the testing email, your consent, given when you send the form and again when you open the confirmation link. You can withdraw it at any time through the unsubscribe link in any of our emails. For the spam check and for recording where you signed up from, our legitimate interest in keeping the form working and in knowing which posts reach people. For counting visits, our legitimate interest in knowing whether the site and its form work. You can object to any of these by writing to us.',
+ );
+ });
+
+ // The owner's approved retention sentence, last in the paragraph, the rest as it was.
+ it('keeps the counts for one year, as the last sentence of the retention paragraph', () => {
+ expect(paragraphs()).toContain(
+ 'How long. Your address is kept until you unsubscribe or ask us to delete it, and no longer than the waitlist is needed for news of the opening; the testing list closes when testing ends, or with the waitlist. Records used to stop the form or the counting being misused are short-lived and deleted automatically. The counts of visits are kept for one year and then deleted.',
+ );
+ });
+
+ it('shows the date the owner approved', () => {
+ expect(renderToStaticMarkup()).toContain('21 November 2026');
+ });
+
+ it('leaves the cookie paragraph exactly as it was', () => {
+ expect(paragraphs()).toContain(COOKIES);
+ });
+
+ it('has the paragraph once', () => {
+ expect(paragraphs().filter((p) => p.startsWith('Counting visits.'))).toHaveLength(1);
+ });
+});
diff --git a/lib/rate-limit.ts b/lib/rate-limit.ts
index a0a8077..69c3bac 100644
--- a/lib/rate-limit.ts
+++ b/lib/rate-limit.ts
@@ -64,6 +64,11 @@ const LIMITERS = {
'client-day': limiter('rl:waitlist:client-day', 10, '24 h'),
address: limiter('rl:waitlist:address', 3, '24 h'),
global: limiter('rl:waitlist:global', 250, '24 h'),
+ // ingest 120 analytics posts a minute per address of origin (the forward
+ // at /ingest). A page sends a handful; this stops the path being
+ // used as a free relay. The window is a minute, so the key is gone
+ // a minute later, well inside the day the other buckets keep.
+ ingest: limiter('rl:ingest:client', 120, '1 m'),
};
export type LimitScope = keyof typeof LIMITERS;
@@ -89,6 +94,15 @@ async function consume(scope: LimitScope, identifier: string): Promise {
+ return consume('ingest', clientKey(headers));
+}
+
/** Count one signup from this client. Checked before the Turnstile call. */
export async function consumeClient(headers: Headers): Promise {
const key = clientKey(headers);
diff --git a/lib/waitlist.ts b/lib/waitlist.ts
index bf2527a..2556096 100644
--- a/lib/waitlist.ts
+++ b/lib/waitlist.ts
@@ -28,7 +28,7 @@ import { TURNSTILE_ACTION, TURNSTILE_ORIGIN } from '@/lib/turnstile';
export type WaitlistResult =
| { status: 'ok' }
| { status: 'invalid'; message: string }
- | { status: 'refused'; message: string };
+ | { status: 'refused'; message: string; limited?: true };
const MESSAGES = {
check:
@@ -98,7 +98,7 @@ export async function joinWaitlist(form: FormData, headers: Headers): Promise=18'
react-dom: '>=18'
+ peerDependenciesMeta:
+ react:
+ optional: true
+ react-dom:
+ optional: true
'@emnapi/core@1.10.0':
resolution: {integrity: sha512-yq6OkJ4p82CAfPl0u9mQebQHKPJkY7WrIuk205cTYnYe+k2Z8YBh11FrbRG/H6ihirqcacOgl2BIO8oyMQLeXw==}
@@ -500,6 +511,15 @@ packages:
'@oxc-project/types@0.156.0':
resolution: {integrity: sha512-1Duyg48TdJNdyhEB8Xn1L36bT9Pv6GUtlKjHxOys8xkaF/rQq3XJE+bAurSK/AgIz5mGFsb77cn9Pb20+WCScw==}
+ '@posthog/browser-common@0.12.2':
+ resolution: {integrity: sha512-ZfqE1ntvsFPaD5I1IRh/wRL6JPW6Zlo8NDTOc0s5OtK7JeER9jE/byLjSHQ1/cKZk3MD8JG7F1hANUhnos6dOg==}
+
+ '@posthog/core@1.69.2':
+ resolution: {integrity: sha512-toMfPKklwLW+a4ZY3/EzM3GNMVXmk2ylGb8NPJXRH4igXMoI8wgNL2jqXOiglWAXqFBLZGYFN1oQx6LVmUTxTg==}
+
+ '@posthog/types@1.427.0':
+ resolution: {integrity: sha512-2RPVfuGIx0iys78mTOcfdzN7/w7AM1Ak3yu9++4/FonPf08mwGqDkJjThz2dA/34666ToNw5Q4fZoFdgvfNUHw==}
+
'@rolldown/binding-android-arm-eabi@1.2.19':
resolution: {integrity: sha512-e+Ebe0WT+9tbXmNKPIiC8YrWAHYwug3m6i4p3rZGGulfZri1jtI4HslT+OZnFf/OIHowWF71DTlHwXBP2SiA7A==}
engines: {node: ^20.19.0 || >=22.12.0}
@@ -639,6 +659,15 @@ packages:
'@types/react@19.2.18':
resolution: {integrity: sha512-AnzbBERsrLKtk2XSfTbYRLjQPdy116Sty4q+T+Bp3IC4l6jNBvreVPAHmpq9qhXQM7CXZPjLVmGMw9sy+hxQ3w==}
+ '@types/trusted-types@2.0.7':
+ resolution: {integrity: sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw==}
+
+ '@types/whatwg-mimetype@3.0.2':
+ resolution: {integrity: sha512-c2AKvDT8ToxLIOUlN51gTiHXflsfIFisS4pO7pDPoKouJCESkhZnEy623gwP9laCy5lnLDAw1vAzu2vM2YLOrA==}
+
+ '@types/ws@8.18.2':
+ resolution: {integrity: sha512-67MQl+fpWKVTT1NYdnmo3U4sc/xPo/zQBncVnI74qmQa0z/b+1g6iYqNmGCPbxO+zz2aklb08a0oHfegiVd0/w==}
+
'@typescript-eslint/eslint-plugin@8.69.0':
resolution: {integrity: sha512-t5jQTKPIgVW1PE6dR6H6Qz5gm8zjMlX5/2gRaOGd9eO6V7J+tQc6iWKukEe7dY8u9HyYasQ0yfF0/FSSTEO2gA==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -951,6 +980,10 @@ packages:
engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}
hasBin: true
+ buffer-image-size@0.6.4:
+ resolution: {integrity: sha512-nEh+kZOPY1w+gcCMobZ6ETUp9WfibndnosbpwB1iJk/8Gt5ZF2bhS6+B6bPYz424KtwsR6Rflc3tCz1/ghX2dQ==}
+ engines: {node: '>=4.0'}
+
call-bind-apply-helpers@1.0.2:
resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==}
engines: {node: '>= 0.4'}
@@ -994,6 +1027,9 @@ packages:
convert-source-map@2.0.0:
resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==}
+ core-js@3.51.0:
+ resolution: {integrity: sha512-7bDKx/5jm5MxzsXxc93g6Z2+4ZsuT/MddrfRmTDJNAkWsYWHU8EVNEsBiIEWnMAMCHMmRfUEjkuo3jeNBOIHRw==}
+
cross-spawn@7.0.6:
resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==}
engines: {node: '>= 8'}
@@ -1052,6 +1088,9 @@ packages:
resolution: {integrity: sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==}
engines: {node: '>=0.10.0'}
+ dompurify@3.4.18:
+ resolution: {integrity: sha512-ofe3wI/uNm68HInABYFJYqQxRw1EaKAjNdrFVKqjUY+UZurvNd2L/HuQe097s/4RivWiZyP6tT7aoT8atjfhwg==}
+
dunder-proto@1.0.1:
resolution: {integrity: sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==}
engines: {node: '>= 0.4'}
@@ -1062,6 +1101,10 @@ packages:
emoji-regex@9.2.2:
resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==}
+ entities@7.0.1:
+ resolution: {integrity: sha512-TWrgLOFUQTH994YUyl1yT4uyavY5nNB5muff+RtWaqNVCAK408b5ZnnbNAUEWLTCpum9w6arT70i1XdQ4UeOPA==}
+ engines: {node: '>=0.12'}
+
es-abstract-get@1.0.0:
resolution: {integrity: sha512-6PMWXpdhshVvFp+FoWYs1EvG1Nj0tvk0dZM+XcK0xMEM1czRVcP6ohqPWHy6qPagSpC8j4+p89WXlT+xXJs/fg==}
engines: {node: '>= 0.4'}
@@ -1262,6 +1305,9 @@ packages:
picomatch:
optional: true
+ fflate@0.4.9:
+ resolution: {integrity: sha512-zdxgIEddhfsyCaWpJ2SdXEP8ZMrKJ6+5jl4OupODcywU0IhRk6gdXuVGcPICyfx2H97hVK7xmJtRLPjkxAX8Vw==}
+
file-entry-cache@8.0.0:
resolution: {integrity: sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==}
engines: {node: '>=16.0.0'}
@@ -1347,6 +1393,10 @@ packages:
resolution: {integrity: sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==}
engines: {node: '>= 0.4'}
+ happy-dom@21.0.4:
+ resolution: {integrity: sha512-tFm+GaLBgo6o0awHnvHaNoraVo27qJ+2tZEtZ+cIa08hXbeitrxAJajLI05hsUy/2/YTKcUjQYzHe5mCcraLBw==}
+ engines: {node: '>=20.0.0'}
+
has-bigints@1.1.0:
resolution: {integrity: sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==}
engines: {node: '>= 0.4'}
@@ -1813,6 +1863,25 @@ packages:
resolution: {integrity: sha512-RVHEU9/Pp1Fnjr/MpAJsZoADukCKhfIi15OunEYiGktIkYLkPVvC1sioWolGDS7XByMTx9m/IGbro0Js13zhnQ==}
engines: {node: ^10 || ^12 || >=14}
+ posthog-js@1.453.2:
+ resolution: {integrity: sha512-dwWSNoTwGPm/dUCcjT69Bnoq7hCx+qPbnX9kax9HR8yjTd7EbIiza1VPW7LZxu7l1JnaZGXFygw4IWQIiqXGeQ==}
+ peerDependencies:
+ '@types/react': '>=16.8.0'
+ react: '>=16.8.0'
+ peerDependenciesMeta:
+ '@types/react':
+ optional: true
+ react:
+ optional: true
+
+ preact@10.29.8:
+ resolution: {integrity: sha512-ej2aVZ+vZ8WO7tvlQWRM9N63A0KzF9q4mWJfDUHgYaIofWY9hu74QdnQrjoPMmZi2/nZ5gN0bJCQF49xQqx09Q==}
+ peerDependencies:
+ preact-render-to-string: '>=5'
+ peerDependenciesMeta:
+ preact-render-to-string:
+ optional: true
+
prelude-ls@1.2.1:
resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==}
engines: {node: '>= 0.8.0'}
@@ -1824,6 +1893,9 @@ packages:
resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==}
engines: {node: '>=6'}
+ query-selector-shadow-dom@1.0.1:
+ resolution: {integrity: sha512-lT5yCqEBgfoMYpf3F2xQRK7zEr1rhIIZuceDK6+xRkJQ4NMbHTwXqk4NkwDwQMNqXgG9r9fyHnzwNVs6zV5KRw==}
+
queue-microtask@1.2.3:
resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==}
@@ -2188,6 +2260,16 @@ packages:
jsdom:
optional: true
+ web-vitals@6.2.1:
+ resolution: {integrity: sha512-rLcLXA2sx6+9dE88NHFubwTtGxpK4yYBLj6qHPdFoCaLr0cXGb4efOqtKLlm4loGA4OEKHIQKMKzZkKyOh5ctw==}
+
+ web-vitals@6.2.3:
+ resolution: {integrity: sha512-Dmy+vdO1UPMqXiAtZSNayhl4f794Bxfd94W4HIj2HlYtczEQfEOon969memlcpcHrTuOKLa5baFjX7WbgmOq+A==}
+
+ whatwg-mimetype@3.0.0:
+ resolution: {integrity: sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q==}
+ engines: {node: '>=12'}
+
which-boxed-primitive@1.1.1:
resolution: {integrity: sha512-TbX3mj8n0odCBFVlY8AxkqcHASw3L60jIuF8jFP78az3C2YhmGvqbHBpAjTRH2/xqYunrJ9g1jSyjCjpoWzIAA==}
engines: {node: '>= 0.4'}
@@ -2218,6 +2300,18 @@ packages:
resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==}
engines: {node: '>=0.10.0'}
+ ws@8.23.0:
+ resolution: {integrity: sha512-wCkmX8QMOrKjgO8HW2WyDbTSGeqkocxgDzS9iR79rEAexty6/2qzilx3Ag8Tqf9ykop3irLKle0MtVn5qjVnoQ==}
+ engines: {node: '>=10.0.0'}
+ peerDependencies:
+ bufferutil: ^4.0.1
+ utf-8-validate: '>=5.0.2'
+ peerDependenciesMeta:
+ bufferutil:
+ optional: true
+ utf-8-validate:
+ optional: true
+
yallist@3.1.1:
resolution: {integrity: sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==}
@@ -2342,7 +2436,7 @@ snapshots:
zod: 4.5.4
'@ekdotico/domico@0.48.0(react-dom@19.2.8(react@19.2.8))(react@19.2.8)':
- dependencies:
+ optionalDependencies:
react: 19.2.8
react-dom: 19.2.8(react@19.2.8)
@@ -2639,6 +2733,21 @@ snapshots:
'@oxc-project/types@0.156.0': {}
+ '@posthog/browser-common@0.12.2':
+ dependencies:
+ '@posthog/core': 1.69.2
+ '@posthog/types': 1.427.0
+ dompurify: 3.4.18
+ preact: 10.29.8
+ transitivePeerDependencies:
+ - preact-render-to-string
+
+ '@posthog/core@1.69.2':
+ dependencies:
+ '@posthog/types': 1.427.0
+
+ '@posthog/types@1.427.0': {}
+
'@rolldown/binding-android-arm-eabi@1.2.19':
optional: true
@@ -2729,6 +2838,15 @@ snapshots:
dependencies:
csstype: 3.2.3
+ '@types/trusted-types@2.0.7':
+ optional: true
+
+ '@types/whatwg-mimetype@3.0.2': {}
+
+ '@types/ws@8.18.2':
+ dependencies:
+ '@types/node': 24.13.3
+
'@typescript-eslint/eslint-plugin@8.69.0(@typescript-eslint/parser@8.69.0(eslint@9.39.5)(typescript@6.0.3))(eslint@9.39.5)(typescript@6.0.3)':
dependencies:
'@eslint-community/regexpp': 4.12.2
@@ -3043,6 +3161,10 @@ snapshots:
node-releases: 2.0.54
update-browserslist-db: 1.3.2(browserslist@4.28.9)
+ buffer-image-size@0.6.4:
+ dependencies:
+ '@types/node': 24.13.3
+
call-bind-apply-helpers@1.0.2:
dependencies:
es-errors: 1.3.0
@@ -3083,6 +3205,8 @@ snapshots:
convert-source-map@2.0.0: {}
+ core-js@3.51.0: {}
+
cross-spawn@7.0.6:
dependencies:
path-key: 3.1.1
@@ -3139,6 +3263,10 @@ snapshots:
dependencies:
esutils: 2.0.3
+ dompurify@3.4.18:
+ optionalDependencies:
+ '@types/trusted-types': 2.0.7
+
dunder-proto@1.0.1:
dependencies:
call-bind-apply-helpers: 1.0.2
@@ -3149,6 +3277,8 @@ snapshots:
emoji-regex@9.2.2: {}
+ entities@7.0.1: {}
+
es-abstract-get@1.0.0:
dependencies:
es-errors: 1.3.0
@@ -3494,6 +3624,8 @@ snapshots:
optionalDependencies:
picomatch: 4.0.7
+ fflate@0.4.9: {}
+
file-entry-cache@8.0.0:
dependencies:
flat-cache: 4.0.1
@@ -3588,6 +3720,19 @@ snapshots:
gopd@1.2.0: {}
+ happy-dom@21.0.4:
+ dependencies:
+ '@types/node': 24.13.3
+ '@types/whatwg-mimetype': 3.0.2
+ '@types/ws': 8.18.2
+ buffer-image-size: 0.6.4
+ entities: 7.0.1
+ whatwg-mimetype: 3.0.0
+ ws: 8.23.0
+ transitivePeerDependencies:
+ - bufferutil
+ - utf-8-validate
+
has-bigints@1.1.0: {}
has-flag@4.0.0: {}
@@ -4030,6 +4175,26 @@ snapshots:
picocolors: 1.1.1
source-map-js: 1.2.4
+ posthog-js@1.453.2(@types/react@19.2.18)(react@19.2.8):
+ dependencies:
+ '@posthog/browser-common': 0.12.2
+ '@posthog/core': 1.69.2
+ '@posthog/types': 1.427.0
+ core-js: 3.51.0
+ dompurify: 3.4.18
+ fflate: 0.4.9
+ preact: 10.29.8
+ query-selector-shadow-dom: 1.0.1
+ web-vitals: 6.2.3
+ web-vitals-soft-navs: web-vitals@6.2.1
+ optionalDependencies:
+ '@types/react': 19.2.18
+ react: 19.2.8
+ transitivePeerDependencies:
+ - preact-render-to-string
+
+ preact@10.29.8: {}
+
prelude-ls@1.2.1: {}
prop-types@15.8.1:
@@ -4040,6 +4205,8 @@ snapshots:
punycode@2.3.1: {}
+ query-selector-shadow-dom@1.0.1: {}
+
queue-microtask@1.2.3: {}
react-dom@19.2.8(react@19.2.8):
@@ -4450,7 +4617,7 @@ snapshots:
'@types/node': 24.13.3
fsevents: 2.3.3
- vitest@5.0.0(@types/node@24.13.3)(vite@8.2.4(@types/node@24.13.3)):
+ vitest@5.0.0(@types/node@24.13.3)(happy-dom@21.0.4)(vite@8.2.4(@types/node@24.13.3)):
dependencies:
'@types/chai': 5.2.3
'@vitest/mocker': 5.0.0(vite@8.2.4(@types/node@24.13.3))
@@ -4468,9 +4635,16 @@ snapshots:
why-is-node-running: 2.3.0
optionalDependencies:
'@types/node': 24.13.3
+ happy-dom: 21.0.4
transitivePeerDependencies:
- msw
+ web-vitals@6.2.1: {}
+
+ web-vitals@6.2.3: {}
+
+ whatwg-mimetype@3.0.0: {}
+
which-boxed-primitive@1.1.1:
dependencies:
is-bigint: 1.1.0
@@ -4523,6 +4697,8 @@ snapshots:
word-wrap@1.2.5: {}
+ ws@8.23.0: {}
+
yallist@3.1.1: {}
yocto-queue@0.1.0: {}
diff --git a/proxy.ts b/proxy.ts
index 2d4b8f4..9b8a14a 100644
--- a/proxy.ts
+++ b/proxy.ts
@@ -28,7 +28,10 @@ export const config = {
// in next.config.ts. It loads its own scripts without a nonce and reads
// Healthchecks.io from the browser, so this site's nonce policy would block
// it. It carries no form and no personal data.
- matcher: ['/((?!_next/|status(?:/|$)|favicon\\.ico$|apple-icon\\.png$|icon\\.svg$|robots\\.txt$|og\\.png$).*)'],
+ //
+ // /ingest is the analytics forward (app/ingest). It returns no page, so it
+ // takes no policy; this site has no gate, so nothing here redirects it.
+ matcher: ['/((?!_next/|ingest(?:/|$)|status(?:/|$)|favicon\\.ico$|apple-icon\\.png$|icon\\.svg$|robots\\.txt$|og\\.png$).*)'],
};
const CSP_HEADER_NAME = 'Content-Security-Policy';
diff --git a/vitest.config.mts b/vitest.config.mts
index fc336a7..c618fbc 100644
--- a/vitest.config.mts
+++ b/vitest.config.mts
@@ -2,5 +2,5 @@ import { defineConfig } from 'vitest/config';
export default defineConfig({
resolve: { alias: { '@': import.meta.dirname } },
- test: { include: ['lib/**/*.test.ts'] },
+ test: { include: ['lib/**/*.test.{ts,tsx}'] },
});