File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed
Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change 11import { minify , type Options } from "html-minifier-terser" ;
22import { building } from "$app/environment" ;
33import type { Handle } from "@sveltejs/kit" ;
4- import {
5- CONTENTFUL_DELIVERY_KEY ,
6- CONTENTFUL_PREVIEW_FLAG ,
7- CONTENTFUL_PREVIEW_KEY ,
8- CONTENTFUL_SPACE_ID ,
9- } from "$env/static/private" ;
4+ // import {
5+ // CONTENTFUL_DELIVERY_KEY,
6+ // CONTENTFUL_PREVIEW_FLAG,
7+ // CONTENTFUL_PREVIEW_KEY,
8+ // CONTENTFUL_SPACE_ID,
9+ // } from "$env/static/private";
10+ import { env } from "$env/dynamic/private" ;
1011import { ContentWrapper } from "$lib/utils/api" ;
1112
1213const contentfulPreviewSearchParam = "preview" ;
1314
15+ const CONTENTFUL_DELIVERY_KEY = env . CONTENTFUL_DELIVERY_KEY ;
16+ const CONTENTFUL_PREVIEW_FLAG = env . CONTENTFUL_PREVIEW_FLAG ;
17+ const CONTENTFUL_PREVIEW_KEY = env . CONTENTFUL_PREVIEW_KEY ;
18+ const CONTENTFUL_SPACE_ID = env . CONTENTFUL_SPACE_ID ;
19+
1420const isPreview = ( url : URL ) =>
1521 url . searchParams . get ( contentfulPreviewSearchParam ) ===
1622 CONTENTFUL_PREVIEW_FLAG ;
You can’t perform that action at this time.
0 commit comments