Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"complete" electron support #2

Closed
wants to merge 33 commits into from
Closed

Conversation

Marcus10110
Copy link

This PR attempts to add electron support to the entire playwright-cli tool, by supporting it just as if it was another browser. Unfortunately, it's a little tricky to do so. I have not implemented "openPage" support for electron, instead replying on a different behavior - opening the url on electron launch, rather than in a later call. I haven't checked to find out if that's possible with electron, hopefully it is.

There are a few type problems, there appears to be no type for electron that extends the Browser interface in playwright, instead we just have the electron launcher type, and the ElectronApplication type, neither of which quite map directly to the types provided for the other browsers.

To solve this, i threw together an electronBrowser object which implements the required Browser methods, but like the rest of this PR, it's not complete.

dependabot bot and others added 3 commits December 5, 2020 07:55
Bumps [highlight.js](https://github.com/highlightjs/highlight.js) from 10.3.2 to 10.4.1.
- [Release notes](https://github.com/highlightjs/highlight.js/releases)
- [Changelog](https://github.com/highlightjs/highlight.js/blob/master/CHANGES.md)
- [Commits](highlightjs/highlight.js@10.3.2...10.4.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [ini](https://github.com/isaacs/ini) from 1.3.5 to 1.3.7.
- [Release notes](https://github.com/isaacs/ini/releases)
- [Commits](npm/ini@v1.3.5...v1.3.7)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@pavelfeldman
Copy link

pavelfeldman commented Dec 11, 2020

If you roll to the HEAD, there should be no need in playwright-electron...

dgozman and others added 26 commits December 11, 2020 15:22
This is a first step to convert to React.
Source now accounts for various stack trace formats.
Network now shows `page.goto` resources.
feat: save/load storage options

User can save the storage, and then load the storage in the next script.

```sh
npx playwright-cli --save-storage=storage.json open www.needs-login.com

npx playwright-cli --load-storage=storage.json codegen www.needs-login.com
```
…: make this handle multiple windows, and play nicely with codegen, which seems to break this...)
@Marcus10110 Marcus10110 force-pushed the feature/electron-support branch from cced3d7 to 7ab13b3 Compare January 23, 2021 01:49
@Marcus10110
Copy link
Author

I think electron support just works out of the box now.

@Marcus10110 Marcus10110 closed this Jan 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants