Skip to content

ScreenCIConfig

ScreenCIConfig = Omit<PlaywrightTestConfig, "retries" | "testDir" | "testMatch" | "use" | "projects"> & object

Defined in: types.ts:1192

optional enableCaptureAudio?: boolean

Enables system audio capture for the whole run. When true, the recording browser is launched in audio mode (unmuted, new headless) so that videos setting recordOptions.captureAudio actually capture sound.

This is a launch-time switch, decided once per worker before any individual video’s options are known, so it must live here at config root rather than in a video’s video.use(). A video that sets captureAudio while this is false throws at record time with a link to the setup docs.

false

optional envFile?: string

Path to a .env file to load before uploading. Relative to the screenci.config.ts file. Use this to load SCREENCI_SECRET and other env vars.

'.env'

projectName: string

Name of the project. Used to identify the project in screenci.com.

optional projects?: Omit<Project, "use"> & object[]

optional record?: object

Options that only affect the screenci record command.

optional upload?: RecordUploadPolicy

Controls whether recordings are uploaded after partial Playwright failures.

'passed-only'

optional recordingDir?: string

Directory that will be searched recursively for *.screenci.* files.

Matches files like example.screenci.ts, demo.screenci.js, etc.

Defaults to './recordings'.

optional test?: object

Options that only affect the screenci test command.

optional mockRecord?: boolean

Keeps recording-style timings enabled during screenci test. Equivalent to passing --mock-record on the CLI.

false

optional use?: Omit<NonNullable<PlaywrightTestConfig["use"]>, "trace"> & object

optional actionTimeout?: number

Timeout in milliseconds for individual actions like click(), fill(), etc.

Separate from the overall test timeout. Defaults to 30 seconds so actions don’t inherit the long test timeout.

30000

optional navigationTimeout?: number

Timeout in milliseconds for page navigations like goto(), waitForNavigation(), etc.

Separate from the overall test timeout. Defaults to 30 seconds.

30000

optional recordOptions?: RecordOptions

Project-wide default record options. Override per video with video.recordOptions(...). Code values are the starting point; they stay editable in the web editor.

optional renderOptions?: RenderOptions

Project-wide default render options. Override per video with video.renderOptions(...). Code values are the starting point; they stay editable in the web editor.

optional trace?: NonNullable<NonNullable<PlaywrightTestConfig["use"]>["trace"]>

When to record traces during test execution. Uses Playwright’s native trace option type.

'retain-on-failure'

optional webServer?: PlaywrightTestConfig["webServer"]

Starts and reuses a development server through Playwright before running videos.

This is useful for generated ScreenCI projects that should record against the app in the parent project directory.