Skip to content

Request: Accept buffers also (not only paths) #171

@spencer-melo-lp

Description

@spencer-melo-lp

Request

Do you folks plan to support passing buffers instead of filepath? So we could skip the filesystem I/O?

Example (with Playwright)

await page.goto(`${prev}${urlPath}`, { waitUntil: "load" });
const bufferA = await page.screenshot(); // returns Buffer, no disk write

await page.goto(`${prev}${urlPath}`, { waitUntil: "load" });
const bufferB = await page.screenshot(); // returns Buffer, no disk write

// Compare
await odiff.compare(bufferA, bufferB, diffPath);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions