GithubHelp home page GithubHelp logo

geekwolverine / puppeteer-sharp-extra Goto Github PK

View Code? Open in Web Editor NEW

This project forked from overmiind/puppeteer-sharp-extra

0.0 0.0 0.0 2.56 MB

Plugin framework for PuppeteerSharp

License: MIT License

JavaScript 47.46% C# 52.03% HTML 0.51%

puppeteer-sharp-extra's Introduction

PuppeteerExtraSharp

NuGet Badge

Puppeteer extra sharp is a .NET port of the Node.js library

Quickstart

// Initialization plugin builder
var extra = new PuppeteerExtra(); 

// Use stealth plugin
extra.Use(new StealthPlugin());   

// Launch the puppeteer browser with plugins
var browser = await extra.LaunchAsync(new LaunchOptions()
{
    Headless = false
});

// Create a new page
var page = await browser.NewPageAsync();

await page.GoToAsync("http://google.com");

// Wait 2 second
await page.WaitForTimeoutAsync(2000);

// Take the screenshot
await page.ScreenshotAsync("extra.png");

Plugin list

๐Ÿด Puppeteer stealth plugin

  • Applies various evasion techniques to make detection of headless puppeteer harder.

๐Ÿ“ƒ Puppeteer anonymize UA plugin

  • Anonymizes the user-agent on all pages.

๐Ÿ’€Puppeteer recaptcha plugin

  • Solves recaptcha automatically

๐Ÿ”งPuppeteer block resources plugin

  • Blocks images, documents etc.

โœ‹More plugins coming soon

API

Use(IPuppeteerExtraPlugin)

Adds a new plugin to plugins list and register it.

  • Returns the same instance of puppeteer extra
  • Parameters: instance of IPuppeteerExtraPlugin interface
var puppeteerExtra = new PuppeteerExtra().Use(new AnonymizeUaPlugin()).Use(new StealthPlugin());

LaunchAsync(LaunchOptions)

  • Return the new puppeteer browser instance with launch options
var browser = new PuppeteerExtra().LaunchAsync(new LaunchOptions());

ConnectAsync(ConnectOptions)

  • Connect to the exiting browser with connect options
var browser = new PuppeteerExtra().ConnectAsync(new ConnectOptions());

GetPlugin()

  • Get plugin from plugin list by type
var stealthPlugin = puppeteerExtra.GetPlugin<StealthPlugin>();

puppeteer-sharp-extra's People

Contributors

overmiind avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.