diff --git a/next.config.js b/next.config.js index 34df58c0..5ee292dc 100644 --- a/next.config.js +++ b/next.config.js @@ -27,6 +27,7 @@ module.exports = { const source = fs.readFileSync(v.module.userRequest, 'utf-8'); return JSON.stringify(source); // Strings need to be wrapped in quotes }, []), + BASE_PATH: JSON.stringify(process.env.BASE_PATH || ''), }) ); diff --git a/src/pages/samples/videoUploadingWebCodecs.tsx b/src/pages/samples/videoUploadingWebCodecs.tsx index 80e6ce21..6e863b62 100644 --- a/src/pages/samples/videoUploadingWebCodecs.tsx +++ b/src/pages/samples/videoUploadingWebCodecs.tsx @@ -5,9 +5,7 @@ function Page(): JSX.Element { ); diff --git a/src/types.d.ts b/src/types.d.ts index d32080f6..d3c73264 100644 --- a/src/types.d.ts +++ b/src/types.d.ts @@ -9,6 +9,7 @@ interface HTMLCanvasElement extends HTMLElement { } declare const __SOURCE__: string; +declare const BASE_PATH: string; // Defined by webpack. declare namespace NodeJS {