Question regarding @awesome-cordova-plugins/in-app-browser

I am attempting to use @awesome-cordova-plugins/in-app-browser in an Ionic v6 web app to provide in app browser capability.

I installed the plugin using the following instructions:

npm install @awesome-cordova-plugins/in-app-browser
npm install cordova-plugin-inappbrowser

The script has the following code:

import { InAppBrowser } from "@awesome-cordova-plugins/in-app-browser"
const iab = InAppBrowser;
const browserRef = iab.create("");
const observable = browserRef.on("beforeload")

When const browserRef = iab.create(""); is executed a browser page opens correctly to

However observable is undefined following the execution of const observable = browserRef.on("beforeload").

I want to be able to add an event listener to monitor when a certain page gets loaded into the in app browser.

Any suggestions?

Did you find a solution?