Home Reference Source
import CRIExtraWARCGenerator from 'node-warc/lib/writers/criExtra.js'
public class | source

CRIExtraWARCGenerator

Extends:

WARCWriterBase → CRIExtraWARCGenerator

WARC Generator for use with puppeteer

See:

Method Summary

Public Methods
public

async generateWARC(capturer: CRIExtraRequestCapturer, genOpts: WARCGenOpts): Promise<void>

public

async generateWarcEntry(request: Request): Promise<void>

Generate a WARC record

Public Methods

public async generateWARC(capturer: CRIExtraRequestCapturer, genOpts: WARCGenOpts): Promise<void> source

Params:

NameTypeAttributeDescription
capturer CRIExtraRequestCapturer

The Puppeteer request capturer that contains requests to be serialized to the WARC

genOpts WARCGenOpts

Options for generating the WARC and optionally generating WARC info, WARC info + Webrecorder Player bookmark list, metadata records

Return:

Promise<void>

A Promise that resolves when WARC generation is complete

public async generateWarcEntry(request: Request): Promise<void> source

Generate a WARC record

Params:

NameTypeAttributeDescription
request Request

A chrome-remote-interface-extra Request object

Return:

Promise<void>