@forad/puppeteer-humanize

🕺 Humanizer functions for Puppeteer

Showing:

Popularity

Downloads/wk

8

GitHub Stars

7

Maintenance

Last Commit

2mos ago

Contributors

1

Package

Dependencies

7

License

MIT

Type Definitions

Built-In

Tree-Shakeable

No?

Categories

Readme

Puppeteer-Humanize

puppeteer-humanize

Humanizer functions for Puppeteer

Install

$ npm install @forad/puppeteer-humanize

Example

Below is an example of the typeInto function.


import { typeInto, TypeIntoConfig } from "@forad/puppeteer-humanize"
import { launch, Browser, Page, ElementHandle } from "puppeteer-extra"


;( async () => {
    const browser: Browser = await launch()
    const page: Page = await browser.newPage()

    await page.goto(`https://foo.bar`)

    const input: ElementHandle | undefined = await page.$(`input#my-input`)

    if (input) {
        // Text to enter into input.
        const text: string = `Zero Cool? Crashed fifteen hundred and seven computers in one day? Biggest crash in history, front page New York Times August 10th, 1988. I thought you was black, man. YO THIS IS ZERO COOL!`
        // Optional action configuration.
        // See `schemas/configs.ts` for full configuration shape.
        const config: TypeIntoConfig = {
            mistakes: {
                chance: 8,
                delay: {
                    min: 50,
                    max: 500
                }
            },
            delays: {
                space: {
                    chance: 70,
                    min: 10,
                    max: 50
                }
            }
        }
        // Deploy the action...
        await typeInto(input, text, config)
    }

    console.log(`Input complete!`)
} )()


Implemented

  • typeInto(element, text, config)

Roadmap

  • GAN Mouse movement actions
  • Improve typing actions
  • Suggest stuff in Discord or Discussions (Not Issue Tracker)

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100