Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@scaleleap/puppeteer

Package Overview
Dependencies
Maintainers
2
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@scaleleap/puppeteer

![](https://raw.githubusercontent.com/ScaleLeap/puppeteer/master/docs/assets/header.png)

  • 1.1.56
  • latest
  • npm
  • Socket score

Version published
Maintainers
2
Created
Source

📦 @scaleleap/puppeteer

A Puppeteer convenience wrapper with stealth mode enabled by default.


Download & Installation

$ npm i -s @scaleleap/puppeteer

Usage

Exports everything the same as puppeteer-core package.

In addition to that, launch method is amended to include an extra option that can enable or disable puppeteer-extra behavior.

Also executablePath is set, and headless is set via PUPPETEER_HEADLESS environment variable.

import { launch } from '@scaleleap/puppeteer'

const await browser = launch({
  extra: {
    // is true by default, but we are just showing the example
    stealth: true
  }
})

Helper Functions

clickAndWait(page: Page, selector: string, clickOptions?: ClickOptions, navigationOptions?: NavigationOptions)

Clicks and waits for network request to complete and resolves.

Environment Variables

The following environment variables are available:

  • PUPPETEER_EXECUTABLE_PATH - the location of the Puppeteer executable.
  • GOOGLE_CHROME_BIN - same as above, but only used inside Heroku buildpack.
  • PUPPETEER_HEADLESS - Whether or not it should run in headless mode. Default: true

Heroku

For Heroku deployments, use a heroku/google-chrome buildpack.

This package will get the Chrome locations from the environment variable provided by the buildpack.

## make sure we are using NodeJS
heroku buildpacks:set heroku/nodejs

## now add chrome buildpack
heroku buildpacks:add heroku/google-chrome

References

Contributing

This repository uses Conventional Commit style commit messages.

Authors or Acknowledgments

License

This project is licensed under the MIT License.

Badges

GitHub Workflow Status NPM License Coveralls Semantic Release

Keywords

FAQs

Package last updated on 10 Nov 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc