Skip to content

Commit 2e72988

Browse files
[fix] Use defineConfig in playwright.i18n.config.ts for TypeScript compilation (#5270)
Update playwright.i18n.config.ts to use defineConfig() instead of PlaywrightTestConfig interface to fix TypeScript compilation issues with 'declare' fields. The defineConfig API provides proper Vite integration for TypeScript/Babel compilation, fixing the error: 'TypeScript declare fields must first be transformed by @babel/plugin-transform-typescript' Fixes compilation error in i18n collection workflow.
1 parent 176ff73 commit 2e72988

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

playwright.i18n.config.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { PlaywrightTestConfig } from '@playwright/test'
1+
import { defineConfig } from '@playwright/test'
22

3-
const config: PlaywrightTestConfig = {
3+
export default defineConfig({
44
testDir: './scripts',
55
use: {
66
baseURL: 'http://localhost:5173',
@@ -9,6 +9,4 @@ const config: PlaywrightTestConfig = {
99
reporter: 'list',
1010
timeout: 60000,
1111
testMatch: /collect-i18n-.*\.ts/
12-
}
13-
14-
export default config
12+
})

0 commit comments

Comments
 (0)