TypeScript 类型参考
实验性包:我们保留在本通知取消之前,为了纠正糟糕的设计决策而进行重大更改的权利。
以下类型是 @remotion/vercel 的 API 的一部分:
🌐 The following types are part of the API of @remotion/vercel:
VercelSandbox
import type {VercelSandbox } from '@remotion/vercel';一个具有 AsyncDisposable 支持的 Sandbox。由 createSandbox() 返回。
🌐 A Sandbox with AsyncDisposable support. Returned by createSandbox().
CreateSandboxOnProgress
import type {CreateSandboxOnProgress } from '@remotion/vercel';progress:一个从0到1的数字,表示总体进度message:当前阶段的可人类阅读的描述
RenderMediaOnVercelProgress
import type {RenderMediaOnVercelProgress } from '@remotion/vercel';一个带有以下成员的判别联合(在 stage 上):
🌐 A discriminated union (on stage) with the following members:
{stage: 'opening-browser', overallProgress: number}- 浏览器正在被打开。{stage: 'selecting-composition', overallProgress: number}- 作品正在被选中。{stage: 'render-progress', progress: RenderMediaProgress, overallProgress: number}- 渲染正在进行中。progress字段包含与RenderMediaProgress相同的字段。
每个变体都包括 overallProgress——一个从 0 到 1 的数字,表示加权的整体进度。
🌐 Every variant includes overallProgress — a number from 0 to 1 representing the weighted overall progress.
用作 renderMediaOnVercel() 的 onProgress 回调类型。
🌐 Used as the onProgress callback type for renderMediaOnVercel().
RenderStillOnVercelProgress
import type {RenderStillOnVercelProgress } from '@remotion/vercel';一个带有以下成员的判别联合(在 stage 上):
🌐 A discriminated union (on stage) with the following members:
{stage: 'opening-browser', overallProgress: number}- 浏览器正在被打开。{stage: 'selecting-composition', overallProgress: number}- 作品正在被选中。
每个变体都包括 overallProgress——一个从 0 到 1 的数字,表示加权的整体进度。
🌐 Every variant includes overallProgress — a number from 0 to 1 representing the weighted overall progress.
用作 renderStillOnVercel() 的 onProgress 回调类型。
🌐 Used as the onProgress callback type for renderStillOnVercel().
VercelBlobAccess
import type {VercelBlobAccess } from '@remotion/vercel';要么是 "public",要么是 "private"。用作 uploadToVercelBlob() 的 access 参数。
🌐 Either "public" or "private". Used as the access parameter for uploadToVercelBlob().