Skip to content

🎥 Make videos programmatically with React

wrap in backticks

Jonny Burger62892215d4a8
diff --git a/packages/docs/docs/config.mdx b/packages/docs/docs/config.mdx
index 7f70177aa2..b966c591cd 100644
--- a/packages/docs/docs/config.mdx
+++ b/packages/docs/docs/config.mdx
@@ -23,7 +23,7 @@ Config.setPixelFormat('yuv444p');
Config.setCodec('h265');
```
-## overrideWebpackConfig()<AvailableFrom v="1.1.0" />
+## `overrideWebpackConfig()`<AvailableFrom v="1.1.0" />
Allows you to insert your custom Webpack config. [See the page about custom Webpack configs](/docs/webpack) for more information.
@@ -39,7 +39,7 @@ Config.overrideWebpackConfig((currentConfiguration) => {
});
```
-## setCachingEnabled()<AvailableFrom v="2.0.0" />
+## `setCachingEnabled()`<AvailableFrom v="2.0.0" />
Enable or disable Webpack caching. Default is `true` which will make the Webpack step in the first run a bit slower but will massively speed up subsequent runs.
@@ -51,7 +51,7 @@ Config.setCachingEnabled(false);
The [command line flag](/docs/cli/render#--bundle-cache) `--bundle-cache` will take precedence over this option.
-## setStudioPort()<AvailableFrom v="4.0.61" />
+## `setStudioPort()`<AvailableFrom v="4.0.61" />
Set the HTTP port for the Studio.
@@ -63,7 +63,7 @@ Config.setStudioPort(3003);
The [command line flag](/docs/cli/studio#--port) `--port` will take precedence over this option.
-## setRendererPort()<AvailableFrom v="4.0.61" />
+## `setRendererPort()`<AvailableFrom v="4.0.61" />
Set the port to be used to host the Webpack bundle.
@@ -75,7 +75,7 @@ Config.setStudioPort(3004);
The [command line flag](/docs/cli/render#--port) `--port` will take precedence over this option.
-## setPublicDir()<AvailableFrom v="3.2.13" />
+## `setPublicDir()`<AvailableFrom v="3.2.13" />
<Options id="public-dir" />
@@ -87,7 +87,7 @@ Config.setPublicDir('./custom-public-dir');
The [command line flag](/docs/cli/render#--public-dir) `--public-dir` will take precedence over this option.
-## setEntryPoint()<AvailableFrom v="3.2.40" />
+## `setEntryPoint()`<AvailableFrom v="3.2.40" />
Sets the Remotion [entry point](/docs/terminology/entry-point), you don't have to specify it for CLI commands.
@@ -99,7 +99,7 @@ Config.setEntryPoint('./src/index.ts');
If you pass an entry point as a CLI argument, it will take precedence.
-## setLevel()<AvailableFrom v="2.0.1" />
+## `setLevel()`<AvailableFrom v="2.0.1" />
Increase or decrease the amount of log messages in the CLI.
Acceptable values:
@@ -117,7 +117,7 @@ Config.setLevel('verbose');
The [command line flag](/docs/cli/render#--log) `--log` will take precedence over this option.
-## setMaxTimelineTracks()<AvailableFrom v="2.1.10" />
+## `setMaxTimelineTracks()`<AvailableFrom v="2.1.10" />
Set how many tracks are being displayed in the timeline in the Studio at most. This does not affect your video, just the amount of tracks shown when previewing. Default `15`.
@@ -127,7 +127,7 @@ import {Config} from '@remotion/cli/config';
Config.setMaxTimelineTracks(20);
```
-## setKeyboardShortcutsEnabled()<AvailableFrom v="3.2.11" />
+## `setKeyboardShortcutsEnabled()`<AvailableFrom v="3.2.11" />
Whether the Studio should react to keyboard shortcuts. Default `true`.
@@ -139,7 +139,7 @@ Config.setKeyboardShortcutsEnabled(false);
The [command line flag](/docs/cli/studio#--disable-keyboard-shortcuts) `--disable-keyboard-shortcuts` will take precedence over this option.
-## setWebpackPollingInMilliseconds()<AvailableFrom v="3.3.11" />
+## `setWebpackPollingInMilliseconds()`<AvailableFrom v="3.3.11" />
Enables Webpack polling instead of the file system event listeners for hot reloading.
This is useful if you are inside a virtual machine or have a remote file system.
@@ -152,7 +152,7 @@ Config.setWebpackPollingInMilliseconds(1000);
The [command line flag](/docs/cli/studio#--webpack-poll) `--webpack-poll` will take precedence over this option.
-## setNumberOfSharedAudioTags()<AvailableFrom v="3.3.2" />
+## `setNumberOfSharedAudioTags()`<AvailableFrom v="3.3.2" />
How many shared audio tags should be mounted in the Studio. Shared audio tags can help prevent playback issues due to audio autoplay policies of the browser. See [this article](/docs/player/autoplay#use-the-numberofsharedaudiotags-property) which covers the same option but for the Player. Default `0`, meaning no autoplay policies are circumvented.
@@ -163,7 +163,7 @@ import {Config} from '@remotion/cli/config';
Config.setNumberOfSharedAudioTags(5);
```
-## setShouldOpenBrowser()<AvailableFrom v="3.3.19" />
+## `setShouldOpenBrowser()`<AvailableFrom v="3.3.19" />
Whether Remotion should open a browser when starting the Studio. Default `true`.
@@ -174,7 +174,7 @@ import {Config} from '@remotion/cli/config';
Config.setShouldOpenBrowser(false);
```
-## setBrowserExecutable()<AvailableFrom v="1.5.0" />
+## `setBrowserExecutable()`<AvailableFrom v="1.5.0" />
Set a custom Chrome or Chromium executable path. By default Remotion will try to find an existing version of Chrome on your system and if not found, it will download one. This flag is useful if you don't have Chrome installed in a standard location and you want to prevent downloading an additional browser or need [support for the H264 codec](/docs/video#codec-support).
@@ -186,7 +186,7 @@ Config.setBrowserExecutable('/usr/bin/google-chrome-stable');
The [command line flag](/docs/cli/render#--browser-executable) `--browser-executable` will take precedence over this option.
-## setDelayRenderTimeoutInMilliseconds()<AvailableFrom v="2.6.3" />
+## `setDelayRenderTimeoutInMilliseconds()`<AvailableFrom v="2.6.3" />
_previously named "setTimeoutInMilliseconds"_
@@ -200,7 +200,7 @@ Config.setDelayRenderTimeoutInMilliseconds(60000);
The [command line flag](/docs/cli/render#--timeout) `--timeout` will take precedence over this option.
-## setChromiumDisableWebSecurity()<AvailableFrom v="2.6.5" />
+## `setChromiumDisableWebSecurity()`<AvailableFrom v="2.6.5" />
This will most notably disable CORS among other security features during rendering.
@@ -214,7 +214,7 @@ Config.setChromiumDisableWebSecurity(true);
The [command line flag](/docs/cli/render#--disable-web-security) `--disable-web-security` will take precedence over this option.
-## setChromiumIgnoreCertificateErrors()<AvailableFrom v="2.6.5" />
+## `setChromiumIgnoreCertificateErrors()`<AvailableFrom v="2.6.5" />
Results in invalid SSL certificates, such as self-signed ones, being ignored during rendering.
@@ -228,7 +228,7 @@ Config.setChromiumIgnoreCertificateErrors(true);
The [command line flag](/docs/cli/render#--ignore-certificate-errors) `--ignore-certificate-errors` will take precedence over this option.
-## setChromiumHeadlessMode()<AvailableFrom v="2.6.5" />
+## `setChromiumHeadlessMode()`<AvailableFrom v="2.6.5" />
<Options id="disable-headless" />
@@ -240,7 +240,7 @@ import {Config} from '@remotion/cli/config';
Config.setChromiumHeadlessMode(false);
```
-## setChromiumMultiProcessOnLinux()<AvailableFrom v="4.0.42" />
+## `setChromiumMultiProcessOnLinux()`<AvailableFrom v="4.0.42" />
<Options id="enable-multiprocess-on-linux" cli />
@@ -254,7 +254,7 @@ Config.setChromiumMultiProcessOnLinux(true);
The [command line flag](/docs/cli/render#--enable-multiprocess-on-linux) `--enable-multiprocess-on-linux` will take precedence over this option.
-## setChromiumOpenGlRenderer
+## `setChromiumOpenGlRenderer()`
<Options id="gl" />
@@ -268,7 +268,7 @@ Config.setChromiumOpenGlRenderer('angle');
The [command line flag](/docs/cli/render#--gl) `--gl` will take precedence over this option.
-## setConcurrency()
+## `setConcurrency()`
Sets how many Puppeteer instances will work on rendering your video in parallel.
Default: `null`, meaning **half of the threads** available on your CPU.
@@ -285,7 +285,7 @@ The [command line flag](/docs/cli/render#--concurrency) `--concurrency` will tak
Try to set your concurrency to `os.cpus().length` to all the threads available on your CPU for faster rendering. The drawback is that other parts of your system might slow down.
:::
-## setVideoImageFormat()<AvailableFrom v="4.0.0" />
+## `setVideoImageFormat()`<AvailableFrom v="4.0.0" />
Determines which in which image format to render the frames. Either:
@@ -299,7 +299,7 @@ import {Config} from '@remotion/cli/config';
Config.setVideoImageFormat('png');
```
-## setStillImageFormat()<AvailableFrom v="4.0.0" />
+## `setStillImageFormat()`<AvailableFrom v="4.0.0" />
Determines which in which image format to render the frames. Either:
@@ -314,7 +314,7 @@ import {Config} from '@remotion/cli/config';
Config.setStillImageFormat('pdf');
```
-## ~~setImageFormat()~~<AvailableFrom v="1.4.0" />
+## ~~`setImageFormat()`~~<AvailableFrom v="1.4.0" />
_Removed in v4.0_
@@ -334,7 +334,7 @@ Config.setImageFormat('png');
The [command line flag](/docs/cli/render#--image-format) `--image-format` will take precedence over this option.
-## setScale()<AvailableFrom v="2.6.7" />
+## `setScale()`<AvailableFrom v="2.6.7" />
[Scales the output frames by the factor you pass in.](/docs/scaling) For example, a 1280x720px frame will become a 1920x1080px frame with a scale factor of `1.5`. Vector elements like fonts and HTML markups will be rendered with extra details. Default: `1`.
@@ -346,7 +346,7 @@ Config.setScale(2);
The [command line flag](/docs/cli/render#--scale) `--scale` will take precedence over this option.
-## setMuted()<AvailableFrom v="3.2.1" />
+## `setMuted()`<AvailableFrom v="3.2.1" />
Disables audio output. Default `false`.
@@ -358,7 +358,7 @@ Config.setMuted(true);
The [command line flag](/docs/cli/render#--muted) `--muted` will take precedence over this option.
-## setEnforceAudioTrack()<AvailableFrom v="3.2.1" />
+## `setEnforceAudioTrack()`<AvailableFrom v="3.2.1" />
Render a silent audio track if there would be none otherwise. Default `false`.
@@ -370,7 +370,7 @@ Config.setEnforceAudioTrack(true);
The [command line flag](/docs/cli/render#--enforce-audio-track) `--enforce-audio-track` will take precedence over this option.
-### setForSeamlessAacConcatenation()<AvailableFrom v="4.0.123" />
+### `setForSeamlessAacConcatenation()`<AvailableFrom v="4.0.123" />
<Options id="for-seamless-aac-concatenation" />
@@ -382,7 +382,7 @@ Config.setForSeamlessAacConcatenation(true);
The [command line flag](/docs/cli/render#--for-seamless-aac-concatenation) `--for-seamless-aac-concatenation` will take precedence over this option.
-## setFrameRange()<AvailableFrom v="2.0.0" />
+## `setFrameRange()`<AvailableFrom v="2.0.0" />
Pass a number to render a still frame or a tuple to render a subset of a video. The frame sequence is zero-indexed.
@@ -402,7 +402,7 @@ Config.setFrameRange([0, 20]); // Render a video only containing the first 21 fr
The [command line flag](/docs/cli/render#--frames) `--frames` will take precedence over this option.
-## setJpegQuality()
+## `setJpegQuality()`
The JPEG quality of each frame. Must be a number between 0 and 100. Will not work if you render PNG frames. [Default: 80](https://github.com/chromium/chromium/blob/99314be8152e688bafbbf9a615536bdbb289ea87/headless/lib/browser/protocol/headless_handler.cc#L32).
@@ -414,11 +414,11 @@ Config.setJpegQuality(90);
The [command line flag](/docs/cli/render#--jpeg-quality) `--jpeg-quality` will take precedence over this option.
-## ~~setQuality()~~
+## ~~`setQuality()`~~
Renamed to `setJpegQuality` in `v4.0.0`.
-## setDotEnvLocation()
+## `setDotEnvLocation()`
Set a custom location for a [`.env`](https://www.npmjs.com/package/dotenv) file. You can specify an absolute path or a relative path in which case it gets resolved based on the current working directory.
@@ -430,7 +430,7 @@ Config.setDotEnvLocation('.my-env');
The [command line flag](/docs/cli/render#--env-file) `--env-file` will take precedence over this option.
-## setEveryNthFrame()
+## `setEveryNthFrame()`
This option may only be set when rendering GIFs. [It determines how many frames are rendered, while the other ones gets skipped in order to lower the FPS of the GIF.](/docs/render-as-gif)
@@ -444,7 +444,7 @@ Config.setEveryNthFrame(2);
The [command line flag](/docs/cli/render#--every-nth-frame) `--every-nth-frame` will take precedence over this option.
-## setNumberOfGifLoops()
+## `setNumberOfGifLoops()`
<Options id="number-of-gif-loops" />
@@ -456,7 +456,7 @@ Config.setNumberOfGifLoops(2);
The [command line flag](/docs/cli/render#--number-of-gif-loops) `--number-of-gif-loops` will take precedence over this option.
-## setOutputLocation()<AvailableFrom v="3.1.6" />
+## `setOutputLocation()`<AvailableFrom v="3.1.6" />
Set the output location of the video or still, relative to the current working directory. The default is `out/{composition}.{container}`. For example, `out/HelloWorld.mp4`.
@@ -468,7 +468,7 @@ Config.setOutputLocation('out/video.mp4');
If you pass another argument to the render command, it will take precedence: `npx remotion render src/index.ts HelloWorld out/video.mp4`.
-## setOverwriteOutput()
+## `setOverwriteOutput()`
Set this to `false` to prevent overwriting Remotion outputs when they already exists.
@@ -482,7 +482,7 @@ Config.setOverwriteOutput(false);
In version 1.x, the default behavior was inverse - Remotion would not override by default.
:::
-## setPixelFormat()
+## `setPixelFormat()`
Controls the pixel format in FFmpeg. [Read more about it here.](https://trac.ffmpeg.org/wiki/Chroma%20Subsampling) Acceptable values: `yuv420p`, `yuv422p`, `yuv444p`, `yuv420p10le`, `yuv422p10le`, `yuv444p10le`. Since v1.4, `yuva420p` is also supported for transparent WebM videos. Since v2.1.7, `yuva444p10le` is also supported for transparent ProRes videos
Default value: `yuv420p`
@@ -495,7 +495,7 @@ Config.setPixelFormat('yuv420p');
The [command line flag](/docs/cli/render#--pixel-format) `--pixel-format` will take precedence over this option.
-## setCodec()<AvailableFrom v="1.4.0" />
+## `setCodec()`<AvailableFrom v="1.4.0" />
Choose one of the supported codecs: `h264` _(default)_, `h265`, `vp8`, `vp9`.
@@ -518,7 +518,7 @@ The [command line flag](/docs/cli/render#--codec) `--codec` will take precedence
**See also**: [Encoding guide](/docs/encoding)
-## setAudioCodec()
+## `setAudioCodec()`
```ts twoslash title="remotion.config.ts"
import {Config} from '@remotion/cli/config';
@@ -537,7 +537,7 @@ The [command line flag](/docs/cli/render#--audio-codec) `--audio-codec` will tak
Refer to the [Encoding guide](/docs/encoding) to see defaults and supported combinations.
-## setProResProfile()<AvailableFrom v="2.1.6" />
+## `setProResProfile()`<AvailableFrom v="2.1.6" />
Set the ProRes profile. This option is only valid if the codec has been set to `prores`.
Possible values: `4444-xq`, `4444`, `hq`, `standard`, `light`, `proxy`.
@@ -552,7 +552,7 @@ Config.setProResProfile('4444');
The [command line flag](/docs/cli/render#--prores-profile) `--prores-profile` will take precedence over this option.
-## setX264Preset()<AvailableFrom v="4.2.2" />
+## `setX264Preset()`<AvailableFrom v="4.2.2" />
Set the Preset profile. This option is only valid if the codec has been set to `h264`.
Possible values: `superfast`, `veryfast`, `faster`, `fast`, `medium`, `slow`, `slower`, `veryslow`, `placebo`,
@@ -568,7 +568,7 @@ The [command line flag](/docs/cli/render#--prores-profile) `--prores-profile` wi
**See also**: [Encoding guide](/docs/encoding), [Transparent videos](/docs/transparent-videos)
-## setImageSequence()<AvailableFrom v="1.4.0" />
+## `setImageSequence()`<AvailableFrom v="1.4.0" />
Set to true if you want to output an image sequence instead of a video.
@@ -580,7 +580,7 @@ Config.setImageSequence(true);
The [command line flag](/docs/cli/render#--sequence) `--sequence` will take precedence over this option.
-## overrideHeight()<AvailableFrom v="3.2.40" />
+## `overrideHeight()`<AvailableFrom v="3.2.40" />
Overrides the height of the rendered video.
@@ -593,7 +593,7 @@ Config.overrideHeight(600);
The [command line flag](/docs/cli/render#--height) `--height` will take precedence over this option.
(see h264 validation?)
-## overrideWidth()<AvailableFrom v="3.2.40" />
+## `overrideWidth()`<AvailableFrom v="3.2.40" />
Overrides the width of the rendered video.
@@ -605,7 +605,7 @@ Config.overrideWidth(900);
The [command line flag](/docs/cli/render#--width) `--width` will take precedence over this option
-## ~~setOutputFormat()~~
+## ~~`setOutputFormat()`~~
_Removed in v4.0.0_
_Deprecated_. Use `setCodec()` and `setImageSequence()` instead.
@@ -622,7 +622,7 @@ The [command line flags](/docs/cli) `--sequence` and `--codec` will take precede
The [command line flag](/docs/cli) `--quality` will take precedence over this option.
-## setCrf()<AvailableFrom v="1.4.0" />
+## `setCrf()`<AvailableFrom v="1.4.0" />
The "Constant Rate Factor" (CRF) of the output. [Use this setting to tell FFmpeg how to trade off size and quality.](/docs/encoding#controlling-quality-using-the-crf-setting)
@@ -845,7 +845,7 @@ Using this feature is discouraged. Before using it, we want to make you aware of
Before you use this hack, reach out to the Remotion team on [Discord](https://remotion.dev/discord) and ask us if we are open to implement the feature you need in a clean way - we often do implement new features quickly based on users feedback.
:::
-## ~~setFfmpegExecutable()~~
+## ~~`setFfmpegExecutable()`~~
_removed in v4.0_
@@ -859,7 +859,7 @@ Config.setFfmpegExecutable('/path/to/custom/ffmpeg');
The [command line flag](/docs/cli/render#--ffmpeg-executable) `--ffmpeg-executable` will take precedence over this option.
-## ~~setFfprobeExecutable()~~
+## ~~`setFfprobeExecutable()`~~
_removed in v4.0_
@@ -873,7 +873,7 @@ Config.setFfprobeExecutable('/path/to/custom/ffprobe');
The [command line flag](/docs/cli/render#--ffprobe-executable-) `--ffprobe-executable` will take precedence over this option.
-## ~~setPort()~~
+## ~~`setPort()`~~
_deprecated in v4.0.61 - use [`setStudioPort()`](/docs/config#setstudioport)_
and [`setRendererPort()`](/docs/config#setrendererport) instead.