- Use `open` or `codegen` commands in the Playwright [CLI](./cli.md):
```sh js
$ npx playwright codegen wikipedia.org
```
```sh python
$ playwright codegen wikipedia.org
```
## Stepping through the Playwright script
When `PWDEBUG` is set, Playwright Inspector window will be opened and the script will be
paused on the first Playwright statement:
<imgwidth="557"alt="Paused on line"src="https://user-images.githubusercontent.com/883973/108614337-71761580-73ae-11eb-9f61-3d29c52c9520.png">
Now we know what action is about to be performed and we can look into the details on that
action. For example, when stopped on an input action such as `click`, the exact point Playwright is about to click is highlighted with the large red dot on the inspected page:
<imgwidth="344"alt="Red dot on inspected page"src="https://user-images.githubusercontent.com/883973/108614363-b69a4780-73ae-11eb-8f5e-51f9c91ec9b4.png">
By the time Playwright has paused on that click action, it has already performed actionability checks that can be found in the log: