@playwright/cli 0.0.61 → 0.0.63

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -27,6 +27,23 @@ npm install -g @playwright/cli@latest
27
27
  playwright-cli --help
28
28
  ```
29
29
 
30
+ ### Installing skills
31
+
32
+ Claude Code, GitHub Copilot and others will use the locally installed skills.
33
+
34
+ ```bash
35
+ playwright-cli install-skills
36
+ ```
37
+
38
+ ### Skills-less operation
39
+
40
+ Point your agent at the CLI and let it cook. It'll read the skill off `playwright-cli --help` on its own:
41
+
42
+ ```
43
+ Test the "add todo" flow on https://demo.playwright.dev/todomvc using playwright-cli.
44
+ Check playwright-cli --help for available commands.
45
+ ```
46
+
30
47
  ## Demo
31
48
 
32
49
  ```
@@ -110,6 +127,7 @@ Manage your sessions as follows:
110
127
  ```bash
111
128
  playwright-cli session-list # list all sessions
112
129
  playwright-cli session-stop [name] # stop session
130
+ playwright-cli session-restart [name] # restart session
113
131
  playwright-cli session-stop-all # stop all sessions
114
132
  playwright-cli session-delete [name] # delete session data along with the profiles
115
133
  ```
@@ -181,6 +199,42 @@ playwright-cli tab-close [index] # close a browser tab
181
199
  playwright-cli tab-select <index> # select a browser tab
182
200
  ```
183
201
 
202
+ ### Storage
203
+
204
+ ```bash
205
+ playwright-cli state-save [filename] # save storage state
206
+ playwright-cli state-load <filename> # load storage state
207
+
208
+ # Cookies
209
+ playwright-cli cookie-list [--domain] # list cookies
210
+ playwright-cli cookie-get <name> # get a cookie
211
+ playwright-cli cookie-set <name> <val> # set a cookie
212
+ playwright-cli cookie-delete <name> # delete a cookie
213
+ playwright-cli cookie-clear # clear all cookies
214
+
215
+ # LocalStorage
216
+ playwright-cli localstorage-list # list localStorage entries
217
+ playwright-cli localstorage-get <key> # get localStorage value
218
+ playwright-cli localstorage-set <k> <v> # set localStorage value
219
+ playwright-cli localstorage-delete <k> # delete localStorage entry
220
+ playwright-cli localstorage-clear # clear all localStorage
221
+
222
+ # SessionStorage
223
+ playwright-cli sessionstorage-list # list sessionStorage entries
224
+ playwright-cli sessionstorage-get <k> # get sessionStorage value
225
+ playwright-cli sessionstorage-set <k> <v> # set sessionStorage value
226
+ playwright-cli sessionstorage-delete <k> # delete sessionStorage entry
227
+ playwright-cli sessionstorage-clear # clear all sessionStorage
228
+ ```
229
+
230
+ ### Network
231
+
232
+ ```bash
233
+ playwright-cli route <pattern> [opts] # mock network requests
234
+ playwright-cli route-list # list active routes
235
+ playwright-cli unroute [pattern] # remove route(s)
236
+ ```
237
+
184
238
  ### DevTools
185
239
 
186
240
  ```bash
@@ -189,6 +243,35 @@ playwright-cli network # list all network requests since loadin
189
243
  playwright-cli run-code <code> # run playwright code snippet
190
244
  playwright-cli tracing-start # start trace recording
191
245
  playwright-cli tracing-stop # stop trace recording
246
+ playwright-cli video-start # start video recording
247
+ playwright-cli video-stop [filename] # stop video recording
248
+ ```
249
+
250
+ ### Install
251
+
252
+ ```bash
253
+ playwright-cli install-browser # install browser
254
+ playwright-cli install-skills # install skills
255
+ ```
256
+
257
+ ### Configuration
258
+
259
+ ```bash
260
+ playwright-cli config [options] # configure session settings
261
+ playwright-cli open --browser=chrome # use specific browser
262
+ playwright-cli open --extension # connect via browser extension
263
+ playwright-cli open --config=file.json # use config file
264
+ ```
265
+
266
+ ### Sessions
267
+
268
+ ```bash
269
+ playwright-cli --session=name <cmd> # run command in named session
270
+ playwright-cli session-list # list all sessions
271
+ playwright-cli session-stop [name] # stop session
272
+ playwright-cli session-restart [name] # restart session
273
+ playwright-cli session-stop-all # stop all sessions
274
+ playwright-cli session-delete [name] # delete session data and profiles
192
275
  ```
193
276
  <!-- END GENERATED CLI HELP -->
194
277
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@playwright/cli",
3
- "version": "0.0.61",
3
+ "version": "0.0.63",
4
4
  "description": "Playwright CLI",
5
5
  "repository": {
6
6
  "type": "git",
@@ -17,12 +17,12 @@
17
17
  "scripts": {
18
18
  "lint": "echo OK",
19
19
  "build": "echo OK",
20
- "test": "echo OK"
20
+ "test": "playwright test"
21
21
  },
22
22
  "dependencies": {
23
23
  "minimist": "^1.2.5",
24
- "playwright": "1.59.0-alpha-1769452054000",
25
- "playwright-core": "1.59.0-alpha-1769452054000"
24
+ "playwright": "1.59.0-alpha-1770157258000",
25
+ "playwright-core": "1.59.0-alpha-1770157258000"
26
26
  },
27
27
  "bin": {
28
28
  "playwright-cli": "playwright-cli.js"
package/playwright-cli.js CHANGED
@@ -16,8 +16,8 @@
16
16
  */
17
17
 
18
18
  const { program } = require('playwright/lib/mcp/terminal/program');
19
- const packageJSON = require('./package.json');
20
- program({ version: packageJSON.version }).catch(e => {
19
+ const packageLocation = require.resolve('./package.json');
20
+ program(packageLocation).catch(e => {
21
21
  console.error(e.message);
22
22
  process.exit(1);
23
23
  });