🎥 Make videos programmatically with React
add article
Jonny Burger5208d9d2011f
diff --git a/packages/core/src/Composition.tsx b/packages/core/src/Composition.tsxindex 75f6c85e7d..0f0eabe5c4 100644--- a/packages/core/src/Composition.tsx+++ b/packages/core/src/Composition.tsx@@ -10,7 +10,7 @@ import {import {CompositionManager} from './CompositionManagerContext.js';import {continueRender, delayRender} from './delay-render.js';import {FolderContext} from './Folder.js';-import {getRemotionEnvironment} from './get-environment.js';+import {getRemotionEnvironment} from './get-remotion-environment.js';import {useIsPlayer} from './is-player.js';import {Loading} from './loading-indicator.js';import {NativeLayersContext} from './NativeLayers.js';diff --git a/packages/docs/docs/get-remotion-environment.md b/packages/docs/docs/get-remotion-environment.mdindex 42d7451459..75dbeae876 100644--- a/packages/docs/docs/get-remotion-environment.md+++ b/packages/docs/docs/get-remotion-environment.md@@ -1,4 +1,5 @@---+image: /generated/articles-docs-get-remotion-environment.pngtitle: getRemotionEnvironment()id: get-remotion-environmentcrumb: "API"@@ -7,9 +8,9 @@ crumb: "API"With the `getRemotionEnvironment()` function , you can retrieve information about the current Remotion Environment.It returns an object with the following properties:-- `isStudio`: Indicates if you are currently in the studio.-- `isRendering`: Tells if one is currently in a render.-- `isPlayer`: Indicates if you are in the Player.+- `isStudio`: If the code gets executed in the [Remotion Studio](/docs/cli/studio).+- `isRendering`: Whether the code gets executed in a render.+- `isPlayer`: Whether a Player is mounted on the current page.This can be useful if you want components to compute some values differently based on the environment you are in.diff --git a/packages/docs/src/data/articles.ts b/packages/docs/src/data/articles.tsindex d78f7c83d4..426f679224 100644--- a/packages/docs/src/data/articles.ts+++ b/packages/docs/src/data/articles.ts@@ -657,6 +657,13 @@ export const articles = [compId: "articles-docs-get-input-props",crumb: "API",},+ {+ id: "get-remotion-environment",+ title: "getRemotionEnvironment()",+ relativePath: "docs/get-remotion-environment.md",+ compId: "articles-docs-get-remotion-environment",+ crumb: "API",+ },{id: "getstaticfiles",title: "getStaticFiles()",diff --git a/packages/docs/static/generated/articles-docs-get-remotion-environment.png b/packages/docs/static/generated/articles-docs-get-remotion-environment.pngnew file mode 100644index 0000000000..c1e6124e81Binary files /dev/null and b/packages/docs/static/generated/articles-docs-get-remotion-environment.png differ