fix: revert to screenshot
This commit is contained in:
@@ -180,10 +180,9 @@ export class RemoteBrowser {
|
|||||||
*/
|
*/
|
||||||
public makeAndEmitScreenshot = async (): Promise<void> => {
|
public makeAndEmitScreenshot = async (): Promise<void> => {
|
||||||
try {
|
try {
|
||||||
const screenshot = await this.currentPage?.content();
|
const screenshot = await this.currentPage?.screenshot();
|
||||||
if (screenshot) {
|
if (screenshot) {
|
||||||
const base64Html = Buffer.from(screenshot).toString('base64');
|
this.emitScreenshot(screenshot.toString('base64'));
|
||||||
this.emitScreenshot(base64Html);
|
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
const { message } = e as Error;
|
const { message } = e as Error;
|
||||||
|
|||||||
Reference in New Issue
Block a user