v2.0 Migration
The following is a list of breaking changes in Remotion 2.0, as a reference for projects wanting to upgrade.
Sequences are 1 frame shorter
Because of a mistake in v1, sequences were 1 frame too long. The new behavior sees each composition be 1 frame shorter, but be consistent with the duration of compositions.
The behavior of sequences is now the following, as explained by an example: If durationInFrames is 60 and from is 0, the sequence goes from frame 0 to 59 (60 frames in total), same as a composition with the same duration. In versions 1.x of Remotion, a sequence with the same attributes would go from frame 0 to 60 (61 frames in total).
Upgrade path: Check your sequence lengths and if necessary, increase the duration by 1 frame.
Node.JS API changes
- The userPropsoption ofrenderFrameshas been renamed toinputProps.
- You now need to pass assetsInfotostitchFramesToVideoif you want your video to have sound. TheassetsInfoobject will be returned byrenderFrames().
Upgrade path: See the updated examples on the SSR page and update your program accordingly.
--overwrite is now default
If an output already exists, Remotion will overwrite it without asking now, unless you disable this behavior.
Upgrade path: Do nothing or adjust the setting in the config file if you like.
Webpack now uses ESBuild instead of Babel
Hopefully you will not notice a difference besides it being much faster. There is a way to go back to Babel, you can read about it here
Upgrade path: Do nothing - should something break, use the legacy Babel plugin and file an issue.
react-dom is a peer dependency
react-dom is not anymore pre-installed, so you need to install manually if you upgrade.
Upgrade to version 2.0
Upgrade all dependencies containing "remotion" in your package.json to version ^2.0.0.
diff
diff
Run npm install afterwards.