🎥 Make videos programmatically with React
rename webpack-defined variable
cnnrhill8f92e89658be
diff --git a/packages/bundler/src/webpack-config.ts b/packages/bundler/src/webpack-config.tsindex cf7be59a51..27712f8340 100644--- a/packages/bundler/src/webpack-config.ts+++ b/packages/bundler/src/webpack-config.ts@@ -71,7 +71,7 @@ export const webpackConfig = ({new webpack.HotModuleReplacementPlugin(),new webpack.DefinePlugin({'process.env.INPUT_PROPS': JSON.stringify(inputProps ?? {}),- 'window.remotion_envRaw': JSON.stringify(env ?? {}),+ 'window.remotion_webpackDefinedEnv': JSON.stringify(env ?? {}),}),]: [diff --git a/packages/core/src/RemotionRoot.tsx b/packages/core/src/RemotionRoot.tsxindex 253b6ff7ad..9c87cccf59 100644--- a/packages/core/src/RemotionRoot.tsx+++ b/packages/core/src/RemotionRoot.tsx@@ -39,7 +39,7 @@ export const RemotionRoot: React.FC = ({children}) => {useEffect(() => {if (typeof window.remotion_env === 'undefined') {// move the object injected by webpack into a global variable- window.remotion_env = window.remotion_envRaw ?? {};+ window.remotion_env = window.remotion_webpackDefinedEnv ?? {};}});diff --git a/packages/core/src/index.ts b/packages/core/src/index.tsindex c915e43f33..8d6ed9ce01 100644--- a/packages/core/src/index.ts+++ b/packages/core/src/index.ts@@ -7,7 +7,7 @@ declare global {getStaticCompositions: () => TCompMetadata[];remotion_setFrame: (frame: number) => void;remotion_collectAssets: () => TAsset[];- remotion_envRaw?: object,+ remotion_webpackDefinedEnv?: object,remotion_env: object,}}