Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nondanee/puppeteer-electron
Use Puppeteer's API with Electron
https://github.com/nondanee/puppeteer-electron
electron puppeteer
Last synced: 17 days ago
JSON representation
Use Puppeteer's API with Electron
- Host: GitHub
- URL: https://github.com/nondanee/puppeteer-electron
- Owner: nondanee
- License: mit
- Created: 2019-07-02T15:09:13.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-09-20T13:28:07.000Z (about 4 years ago)
- Last Synced: 2024-10-22T09:10:48.776Z (23 days ago)
- Topics: electron, puppeteer
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/puppeteer-electron
- Size: 15.6 KB
- Stars: 23
- Watchers: 2
- Forks: 9
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Puppeteer-Electron
> A version of Puppeteer that use Electron instead of Chromium
⚠️ BEWARE: Experimental. Just for test. Can not work with all Puppeteer APIs.
## Motivation
In comparison with the full-featured Chromium browser (~108MB Mac, ~113MB Linux, ~141MB Win for ZIP package), A portable alternative ------ Electron is able to handle most daily tasks but has half of Chromium's size (~55MB Mac, ~63MB Linux, ~58MB Win for ZIP package)
## Usage
```javascript
const puppeteer = require('puppeteer-electron');(async () => {
const app = await puppeteer.launch({ headless: false }) // default is true
const pages = await app.pages()
const [page] = pages
await page.goto('https://bing.com')setTimeout(async () => await app.close(), 5000)
})()
```## Reference
- https://discuss.atom.io/t/solved-control-automate-an-electron-application-with-puppeteer/64126
- https://stackoverflow.com/questions/51847667/how-to-automate-electronjs-app
- https://github.com/peterdanis/electron-puppeteer-demo
- https://github.com/electron/electron/issues/3331
- https://github.com/electron/electron/issues/11515## License
The MIT License