home / skills / microsoft / playwright / playwright-dev
This skill explains how to develop Playwright by adding APIs, MCP tools, CLI commands, and vendor dependencies for maintainable core.
npx playbooks add skill microsoft/playwright --skill playwright-devReview the files below or copy the command above to add this skill to your agents.
---
name: playwright-dev
description: Explains how to develop Playwright - add APIs, MCP tools, CLI commands, and vendor dependencies.
---
# Playwright Development Guide
## Table of Contents
- [Adding and Modifying APIs](api.md) — define API docs, implement client/server, add tests
- [MCP Tools and CLI Commands](mcp-dev.md) — add MCP tools, CLI commands, config options
- [Vendoring Dependencies](vendor.md) — bundle third-party npm packages into playwright-core or playwright
## Build
- Assume watch is running and everything is up to date.
- If not, run `npm run build`.
## Lint
- Run `npm run flint` to lint everything before commit.
This skill explains how to develop Playwright by adding or modifying APIs, extending MCP tools and CLI commands, and vendoring third-party dependencies. It focuses on practical steps for implementation, testing, and integrating changes into the TypeScript codebase. The guidance assumes a local build/watch workflow and includes linting and testing reminders.
The skill describes how to define API surface and documentation, implement client and server changes in TypeScript, and add unit and integration tests to validate behavior. It shows how to extend MCP tools and CLI commands with new options and configuration, and how to vendor npm packages into playwright-core or the main playwright package. It also covers the development workflow: build/watch, run tests, and lint before committing.
Do I need to rebuild the repo after changes?
Yes — run the watch build or npm run build if the watch is not running to compile TypeScript changes.
How do I ensure my CLI changes are correct?
Add unit tests for CLI parsing, integration tests for command behavior, and update documentation for new options.
What is the linting command to run before commit?
Run npm run flint to lint the codebase before committing changes.