Set up and scaffold a Playwright TypeScript test framework for web applications. Use when users ask to initialize Playwright, bootstrap a new E2E structure, add Page Object Model foundations, configure fixtures and environments, or fix setup issues such as missing installs and broken first-run commands.
How this skill is triggered — by the user, by Claude, or both
Slash command
/playwright-test-setup:playwright-test-setupThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Creates a reliable starting point for Playwright plus TypeScript, with an optional full framework template.
GETTING_STARTED.mdexamples/README.mdexamples/basic-example.spec.ts.mdexamples/console-logging-example.spec.ts.mdexamples/framework/README.mdexamples/framework/config/environments/prod.ts.mdexamples/framework/config/environments/qa.ts.mdexamples/framework/config/environments/staging.ts.mdexamples/framework/config/projects.ts.mdexamples/framework/objects/components/cardComponent.ts.mdexamples/framework/objects/components/navigationComponent.ts.mdexamples/framework/objects/pages/basePage.ts.mdexamples/framework/objects/pages/loginPage.ts.mdexamples/framework/package.json.mdexamples/framework/playwright.config.ts.mdexamples/framework/testFixtures/base.ts.mdexamples/framework/tests/basic-test.spec.ts.mdexamples/framework/tests/console-logging.spec.ts.mdexamples/framework/tests/element-discovery.spec.ts.mdexamples/framework/tests/form-interaction.spec.ts.mdCreates a reliable starting point for Playwright plus TypeScript, with an optional full framework template.
How this fits together: use this skill for framework setup, use playwright-cli for live exploration, and use playwright-test-gen to convert manual Given/When/Then tests into Playwright specs.
See the workflow guide: workflow-guide.md
Confirm project state. Determine whether this is a new test project or an existing codebase adding Playwright.
Install core dependencies. Ensure package initialization plus required Playwright and TypeScript dependencies are installed.
Install browsers. Run Playwright browser installation after dependency install.
Choose setup mode. Use quick mode for simple tests or framework mode for team-scale suites.
Scaffold files. For framework mode, copy and adapt the structure from the framework example references.
Validate first test run. Execute a minimal test command and confirm environment, browser, and command wiring all work.
Apply baseline quality rules. Prefer stable locators, independent tests, and dynamic waits.
Note: example implementation files in this skill are markdown references (*.md) and are intended to be copied into a target runnable project.
Use when the user needs immediate coverage and minimal structure.
Use when the user needs a scalable suite.
When setup is flagged by missing installs:
package.json.npx playwright installpage.waitForLoadState('networkidle')waitForSelector instead of fixed timeoutsnpx playwright test --debugFor tests that require a running development server, configure the web server in playwright.config.ts:
export default defineConfig({
webServer: {
command: 'npm run dev',
url: 'http://localhost:3000',
reuseExistingServer: !process.env.CI,
},
});
This will automatically start your server before running tests and shut it down after.
See examples/ directory for:
Provides a checklist for code reviews covering functionality, security, performance, maintainability, tests, and quality. Use for pull requests, audits, team standards, and developer training.
npx claudepluginhub tomrobinson26/qa-skills --plugin playwright-test-setup