From 8cebb82baee8a2f3eab6fac59ba0f0397e78d86c Mon Sep 17 00:00:00 2001 From: Dallas Hoffman Date: Wed, 13 Sep 2023 01:02:55 -0400 Subject: [PATCH] Change preview npm command to use firebase serve; fix headers --- firebase.json | 13 +++++++++++++ package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/firebase.json b/firebase.json index 42c0b97..8de9e39 100644 --- a/firebase.json +++ b/firebase.json @@ -21,6 +21,19 @@ "value": "same-origin" } ] + }, + { + "source": "**/*", + "headers": [ + { + "key": "Cross-Origin-Embedder-Policy", + "value": "require-corp" + }, + { + "key": "Cross-Origin-Opener-Policy", + "value": "same-origin" + } + ] } ] } diff --git a/package.json b/package.json index 423024b..36b29ff 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "scripts": { "dev": "vite dev", "build": "vite build", - "preview": "vite preview", + "preview": "firebase serve", "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch", "lint": "prettier --plugin-search-dir . --check .",