fix: add on load socket emit
This commit is contained in:
@@ -370,11 +370,11 @@ export class RemoteBrowser {
|
|||||||
await this.stopScreencast();
|
await this.stopScreencast();
|
||||||
this.currentPage = page;
|
this.currentPage = page;
|
||||||
|
|
||||||
this.currentPage.on('framenavigated', (frame) => {
|
// this.currentPage.on('framenavigated', (frame) => {
|
||||||
if (frame === this.currentPage?.mainFrame()) {
|
// if (frame === this.currentPage?.mainFrame()) {
|
||||||
this.socket.emit('urlChanged', this.currentPage.url());
|
// this.socket.emit('urlChanged', this.currentPage.url());
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
|
|
||||||
//await this.currentPage.setViewportSize({ height: 400, width: 900 })
|
//await this.currentPage.setViewportSize({ height: 400, width: 900 })
|
||||||
this.client = await this.currentPage.context().newCDPSession(this.currentPage);
|
this.client = await this.currentPage.context().newCDPSession(this.currentPage);
|
||||||
|
|||||||
Reference in New Issue
Block a user