Saltar al contenido principal

Function: readTexts()

function readTexts(page, selector): Promise<string[]>;

Defined in: core/text.ts:19

The text of the elements matching selector in page, one string each: paragraphs, line breaks and list items kept, scripts and styles left out. Runs in the page with no named functions inside (see the conventions on page.evaluate).

Parameters​

ParameterType
pagePage
selectorstring

Returns​

Promise<string[]>