From 69ff66db885b04e496ccad4836942e8d76b7b050 Mon Sep 17 00:00:00 2001 From: Seth Battis Date: Tue, 31 Dec 2024 14:17:06 -0500 Subject: [PATCH] feat: add PuppeteerSession.Base.url() method --- packages/datadirect-puppeteer/src/PuppeteerSession/Base.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/datadirect-puppeteer/src/PuppeteerSession/Base.ts b/packages/datadirect-puppeteer/src/PuppeteerSession/Base.ts index 96bd0b9..3269ab4 100644 --- a/packages/datadirect-puppeteer/src/PuppeteerSession/Base.ts +++ b/packages/datadirect-puppeteer/src/PuppeteerSession/Base.ts @@ -90,6 +90,10 @@ export class Base extends EventEmitter { return await new Base(page).ready(); } + public url() { + return new URL(this.page.url()); + } + public async fetch( input: URL | string, init?: RequestInit