{"id":13795447,"url":"https://github.com/Cap-go/capacitor-inappbrowser","last_synced_at":"2025-05-12T22:31:07.986Z","repository":{"id":65435961,"uuid":"515302020","full_name":"Cap-go/capacitor-inappbrowser","owner":"Cap-go","description":"Capacitor plugin in app browser with urlChangeEvent","archived":false,"fork":false,"pushed_at":"2024-11-05T19:17:54.000Z","size":1816,"stargazers_count":71,"open_issues_count":27,"forks_count":52,"subscribers_count":4,"default_branch":"main","last_synced_at":"2024-11-10T00:02:53.740Z","etag":null,"topics":["browser","capacitor","capacitor-plugin"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cap-go.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"Cap-go","patreon":null,"open_collective":"capgo","ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2022-07-18T18:41:49.000Z","updated_at":"2024-11-07T07:55:18.000Z","dependencies_parsed_at":"2023-10-11T04:49:05.096Z","dependency_job_id":"e41155ff-b584-40dd-80f8-b0a7f0eb6097","html_url":"https://github.com/Cap-go/capacitor-inappbrowser","commit_stats":{"total_commits":522,"total_committers":25,"mean_commits":20.88,"dds":0.6091954022988506,"last_synced_commit":"7f64a364c4e3c7c033059152dd430755ea5df62a"},"previous_names":[],"tags_count":212,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cap-go%2Fcapacitor-inappbrowser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cap-go%2Fcapacitor-inappbrowser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cap-go%2Fcapacitor-inappbrowser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cap-go%2Fcapacitor-inappbrowser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cap-go","download_url":"https://codeload.github.com/Cap-go/capacitor-inappbrowser/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224194791,"owners_count":17271527,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["browser","capacitor","capacitor-plugin"],"created_at":"2024-08-03T23:00:57.097Z","updated_at":"2025-05-12T22:31:07.961Z","avatar_url":"https://github.com/Cap-go.png","language":"Java","funding_links":["https://github.com/sponsors/Cap-go","https://opencollective.com/capgo"],"categories":["Plugins","Capgo Capacitor Plugins","[Capgo plugins](https://capgo.app/)"],"sub_categories":["Community Plugins","UI \u0026 Display"],"readme":"# @capgo/inappbrowser\n \u003ca href=\"https://capgo.app/\"\u003e\u003cimg src='https://raw.githubusercontent.com/Cap-go/capgo/main/assets/capgo_banner.png' alt='Capgo - Instant updates for capacitor'/\u003e\u003c/a\u003e\n\n\u003cdiv align=\"center\"\u003e\n  \u003ch2\u003e\u003ca href=\"https://capgo.app/?ref=plugin\"\u003e ➡️ Get Instant updates for your App with Capgo 🚀\u003c/a\u003e\u003c/h2\u003e\n  \u003ch2\u003e\u003ca href=\"https://capgo.app/consulting/?ref=plugin\"\u003e Fix your annoying bug now, Hire a Capacitor expert 💪\u003c/a\u003e\u003c/h2\u003e\n\u003c/div\u003e\n\nCapacitor plugin in app browser with urlChangeEvent, two way communication, camera and microphone usage, etc.\n\n## Install\n\n```bash\nnpm install @capgo/inappbrowser\nnpx cap sync\n```\n## Usage\n\n```js\nimport { InAppBrowser } from '@capgo/inappbrowser'\n\nInAppBrowser.open({ url: \"YOUR_URL\" });\n```\n\nWeb platform is not supported. Use `window.open` instead.\n\n\n### Test app and code:\n\nhttps://github.com/Cap-go/demo-app/blob/main/src/views/plugins/Web.vue\n\n### Camera usage\n\n#### Android\n\nAdd the following to your `AndroidManifest.xml` file:\n\n```xml\n    \u003cuses-permission android:name=\"android.permission.CAMERA\" /\u003e\n\t\t\u003cuses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\" /\u003e\n\t\t\u003cuses-permission android:name=\"android.permission.RECORD_AUDIO\"/\u003e\n```\n\nThen the permission will be asked when the camera is used.\n\n#### iOS\n\nAdd the following to your `Info.plist` file:\n\n```xml\n\u003ckey\u003eNSCameraUsageDescription\u003c/key\u003e\n\u003cstring\u003eWe need access to the camera to record audio.\u003c/string\u003e\n```\n\n### Microphone usage\n\n#### Android\n\nAdd the following to your `AndroidManifest.xml` file:\n\n```xml\n\u003cuses-permission android:name=\"android.permission.RECORD_AUDIO\" /\u003e\n\u003cuses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\" /\u003e\n```\n\nThen the permission will be asked when the microphone is used.\n\n#### iOS\n\nAdd the following to your `Info.plist` file:\n\n```xml\n\u003ckey\u003eNSMicrophoneUsageDescription\u003c/key\u003e\n\u003cstring\u003eWe need access to the microphone to record audio.\u003c/string\u003e\n```\n\n### Two way communication\n\nWith this plugin you can send events from the main app to the inappbrowser and vice versa.\n\n\u003e The data is sent as a JSON object, so no functions or other non-JSON-serializable types are allowed.\n\n#### Main app to inappbrowser, detail object is mendatory\n\n```js\nInAppBrowser.postMessage({ detail: { message: \"myMessage\" } });\n```\n\n#### Receive event from native in the inappbrowser\n\n```js\nwindow.addEventListener(\"messageFromNative\", (event) =\u003e {\n  console.log(event);\n});\n```\n\n#### Send event from inappbrowser to main app, detail object is mendatory\n\n```js\nwindow.mobileApp.postMessage({ detail: { message: \"myMessage\" } });\n```\n\n#### Receive event from inappbrowser in the main app\n\n```js\nwindow.addEventListener(\"messageFromWebview\", (event) =\u003e {\n  console.log(event);\n});\n```\n\n### Close inappbrowser from inappbrowser itself\n\n```js\nwindow.mobileApp.close();\n```\n\n## API\n\n\u003cdocgen-index\u003e\n\n* [`open(...)`](#open)\n* [`clearCookies(...)`](#clearcookies)\n* [`clearAllCookies()`](#clearallcookies)\n* [`clearCache()`](#clearcache)\n* [`getCookies(...)`](#getcookies)\n* [`close()`](#close)\n* [`openWebView(...)`](#openwebview)\n* [`executeScript(...)`](#executescript)\n* [`postMessage(...)`](#postmessage)\n* [`setUrl(...)`](#seturl)\n* [`addListener('urlChangeEvent', ...)`](#addlistenerurlchangeevent-)\n* [`addListener('buttonNearDoneClick', ...)`](#addlistenerbuttonneardoneclick-)\n* [`addListener('closeEvent', ...)`](#addlistenercloseevent-)\n* [`addListener('confirmBtnClicked', ...)`](#addlistenerconfirmbtnclicked-)\n* [`addListener('messageFromWebview', ...)`](#addlistenermessagefromwebview-)\n* [`addListener('browserPageLoaded', ...)`](#addlistenerbrowserpageloaded-)\n* [`addListener('pageLoadError', ...)`](#addlistenerpageloaderror-)\n* [`removeAllListeners()`](#removealllisteners)\n* [`reload()`](#reload)\n* [Interfaces](#interfaces)\n* [Type Aliases](#type-aliases)\n* [Enums](#enums)\n\n\u003c/docgen-index\u003e\n\n\u003cdocgen-api\u003e\n\u003c!--Update the source file JSDoc comments and rerun docgen to update the docs below--\u003e\n\n### open(...)\n\n```typescript\nopen(options: OpenOptions) =\u003e Promise\u003cany\u003e\n```\n\nOpen url in a new window fullscreen, on android it use chrome custom tabs, on ios it use SFSafariViewController\n\n| Param         | Type                                                |\n| ------------- | --------------------------------------------------- |\n| **`options`** | \u003ccode\u003e\u003ca href=\"#openoptions\"\u003eOpenOptions\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n**Since:** 0.1.0\n\n--------------------\n\n\n### clearCookies(...)\n\n```typescript\nclearCookies(options: ClearCookieOptions) =\u003e Promise\u003cany\u003e\n```\n\nClear cookies of url\n\n| Param         | Type                                                              |\n| ------------- | ----------------------------------------------------------------- |\n| **`options`** | \u003ccode\u003e\u003ca href=\"#clearcookieoptions\"\u003eClearCookieOptions\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n**Since:** 0.5.0\n\n--------------------\n\n\n### clearAllCookies()\n\n```typescript\nclearAllCookies() =\u003e Promise\u003cany\u003e\n```\n\nClear all cookies\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n**Since:** 6.5.0\n\n--------------------\n\n\n### clearCache()\n\n```typescript\nclearCache() =\u003e Promise\u003cany\u003e\n```\n\nClear cache\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n**Since:** 6.5.0\n\n--------------------\n\n\n### getCookies(...)\n\n```typescript\ngetCookies(options: GetCookieOptions) =\u003e Promise\u003cRecord\u003cstring, string\u003e\u003e\n```\n\nGet cookies for a specific URL.\n\n| Param         | Type                                                          | Description                                        |\n| ------------- | ------------------------------------------------------------- | -------------------------------------------------- |\n| **`options`** | \u003ccode\u003e\u003ca href=\"#getcookieoptions\"\u003eGetCookieOptions\u003c/a\u003e\u003c/code\u003e | The options, including the URL to get cookies for. |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#record\"\u003eRecord\u003c/a\u003e\u0026lt;string, string\u0026gt;\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### close()\n\n```typescript\nclose() =\u003e Promise\u003cany\u003e\n```\n\nClose the webview.\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### openWebView(...)\n\n```typescript\nopenWebView(options: OpenWebViewOptions) =\u003e Promise\u003cany\u003e\n```\n\nOpen url in a new webview with toolbars, and enhanced capabilities, like camera access, file access, listen events, inject javascript, bi directional communication, etc.\n\nJavaScript Interface:\nWhen you open a webview with this method, a JavaScript interface is automatically injected that provides:\n- `window.mobileApp.close()`: Closes the webview from JavaScript\n- `window.mobileApp.postMessage({detail: {message: 'myMessage'}})`: Sends a message from the webview to the app, detail object is the data you want to send to the webview\n\n| Param         | Type                                                              |\n| ------------- | ----------------------------------------------------------------- |\n| **`options`** | \u003ccode\u003e\u003ca href=\"#openwebviewoptions\"\u003eOpenWebViewOptions\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n**Since:** 0.1.0\n\n--------------------\n\n\n### executeScript(...)\n\n```typescript\nexecuteScript({ code }: { code: string; }) =\u003e Promise\u003cvoid\u003e\n```\n\nInjects JavaScript code into the InAppBrowser window.\n\n| Param     | Type                           |\n| --------- | ------------------------------ |\n| **`__0`** | \u003ccode\u003e{ code: string; }\u003c/code\u003e |\n\n--------------------\n\n\n### postMessage(...)\n\n```typescript\npostMessage(options: { detail: Record\u003cstring, any\u003e; }) =\u003e Promise\u003cvoid\u003e\n```\n\nSends an event to the webview(inappbrowser). you can listen to this event in the inappbrowser JS with window.addEventListener(\"messageFromNative\", listenerFunc: (event: \u003ca href=\"#record\"\u003eRecord\u003c/a\u003e\u0026lt;string, any\u0026gt;) =\u0026gt; void)\ndetail is the data you want to send to the webview, it's a requirement of Capacitor we cannot send direct objects\nYour object has to be serializable to JSON, so no functions or other non-JSON-serializable types are allowed.\n\n| Param         | Type                                                                      |\n| ------------- | ------------------------------------------------------------------------- |\n| **`options`** | \u003ccode\u003e{ detail: \u003ca href=\"#record\"\u003eRecord\u003c/a\u003e\u0026lt;string, any\u0026gt;; }\u003c/code\u003e |\n\n--------------------\n\n\n### setUrl(...)\n\n```typescript\nsetUrl(options: { url: string; }) =\u003e Promise\u003cany\u003e\n```\n\nSets the URL of the webview.\n\n| Param         | Type                          |\n| ------------- | ----------------------------- |\n| **`options`** | \u003ccode\u003e{ url: string; }\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### addListener('urlChangeEvent', ...)\n\n```typescript\naddListener(eventName: \"urlChangeEvent\", listenerFunc: UrlChangeListener) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\nListen for url change, only for openWebView\n\n| Param              | Type                                                            |\n| ------------------ | --------------------------------------------------------------- |\n| **`eventName`**    | \u003ccode\u003e'urlChangeEvent'\u003c/code\u003e                                   |\n| **`listenerFunc`** | \u003ccode\u003e\u003ca href=\"#urlchangelistener\"\u003eUrlChangeListener\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n**Since:** 0.0.1\n\n--------------------\n\n\n### addListener('buttonNearDoneClick', ...)\n\n```typescript\naddListener(eventName: \"buttonNearDoneClick\", listenerFunc: ButtonNearListener) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\n| Param              | Type                                                              |\n| ------------------ | ----------------------------------------------------------------- |\n| **`eventName`**    | \u003ccode\u003e'buttonNearDoneClick'\u003c/code\u003e                                |\n| **`listenerFunc`** | \u003ccode\u003e\u003ca href=\"#buttonnearlistener\"\u003eButtonNearListener\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### addListener('closeEvent', ...)\n\n```typescript\naddListener(eventName: \"closeEvent\", listenerFunc: UrlChangeListener) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\nListen for close click only for openWebView\n\n| Param              | Type                                                            |\n| ------------------ | --------------------------------------------------------------- |\n| **`eventName`**    | \u003ccode\u003e'closeEvent'\u003c/code\u003e                                       |\n| **`listenerFunc`** | \u003ccode\u003e\u003ca href=\"#urlchangelistener\"\u003eUrlChangeListener\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n**Since:** 0.4.0\n\n--------------------\n\n\n### addListener('confirmBtnClicked', ...)\n\n```typescript\naddListener(eventName: \"confirmBtnClicked\", listenerFunc: ConfirmBtnListener) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\nWill be triggered when user clicks on confirm button when disclaimer is required\n\n| Param              | Type                                                              |\n| ------------------ | ----------------------------------------------------------------- |\n| **`eventName`**    | \u003ccode\u003e'confirmBtnClicked'\u003c/code\u003e                                  |\n| **`listenerFunc`** | \u003ccode\u003e\u003ca href=\"#confirmbtnlistener\"\u003eConfirmBtnListener\u003c/a\u003e\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n**Since:** 0.0.1\n\n--------------------\n\n\n### addListener('messageFromWebview', ...)\n\n```typescript\naddListener(eventName: \"messageFromWebview\", listenerFunc: (event: { detail: Record\u003cstring, any\u003e; }) =\u003e void) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\nWill be triggered when event is sent from webview(inappbrowser), to send an event to the main app use window.mobileApp.postMessage({ \"detail\": { \"message\": \"myMessage\" } })\ndetail is the data you want to send to the main app, it's a requirement of Capacitor we cannot send direct objects\nYour object has to be serializable to JSON, no functions or other non-JSON-serializable types are allowed.\n\nThis method is inject at runtime in the webview\n\n| Param              | Type                                                                                          |\n| ------------------ | --------------------------------------------------------------------------------------------- |\n| **`eventName`**    | \u003ccode\u003e'messageFromWebview'\u003c/code\u003e                                                             |\n| **`listenerFunc`** | \u003ccode\u003e(event: { detail: \u003ca href=\"#record\"\u003eRecord\u003c/a\u003e\u0026lt;string, any\u0026gt;; }) =\u0026gt; void\u003c/code\u003e |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### addListener('browserPageLoaded', ...)\n\n```typescript\naddListener(eventName: \"browserPageLoaded\", listenerFunc: () =\u003e void) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\nWill be triggered when page is loaded\n\n| Param              | Type                             |\n| ------------------ | -------------------------------- |\n| **`eventName`**    | \u003ccode\u003e'browserPageLoaded'\u003c/code\u003e |\n| **`listenerFunc`** | \u003ccode\u003e() =\u0026gt; void\u003c/code\u003e       |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### addListener('pageLoadError', ...)\n\n```typescript\naddListener(eventName: \"pageLoadError\", listenerFunc: () =\u003e void) =\u003e Promise\u003cPluginListenerHandle\u003e\n```\n\nWill be triggered when page load error\n\n| Param              | Type                         |\n| ------------------ | ---------------------------- |\n| **`eventName`**    | \u003ccode\u003e'pageLoadError'\u003c/code\u003e |\n| **`listenerFunc`** | \u003ccode\u003e() =\u0026gt; void\u003c/code\u003e   |\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;\u003ca href=\"#pluginlistenerhandle\"\u003ePluginListenerHandle\u003c/a\u003e\u0026gt;\u003c/code\u003e\n\n--------------------\n\n\n### removeAllListeners()\n\n```typescript\nremoveAllListeners() =\u003e Promise\u003cvoid\u003e\n```\n\nRemove all listeners for this plugin.\n\n**Since:** 1.0.0\n\n--------------------\n\n\n### reload()\n\n```typescript\nreload() =\u003e Promise\u003cany\u003e\n```\n\nReload the current web page.\n\n**Returns:** \u003ccode\u003ePromise\u0026lt;any\u0026gt;\u003c/code\u003e\n\n**Since:** 1.0.0\n\n--------------------\n\n\n### Interfaces\n\n\n#### OpenOptions\n\n| Prop                         | Type                 | Description                                                                                                           | Since |\n| ---------------------------- | -------------------- | --------------------------------------------------------------------------------------------------------------------- | ----- |\n| **`url`**                    | \u003ccode\u003estring\u003c/code\u003e  | Target URL to load.                                                                                                   | 0.1.0 |\n| **`isPresentAfterPageLoad`** | \u003ccode\u003eboolean\u003c/code\u003e | if true, the browser will be presented after the page is loaded, if false, the browser will be presented immediately. | 0.1.0 |\n| **`preventDeeplink`**        | \u003ccode\u003eboolean\u003c/code\u003e | if true the deeplink will not be opened, if false the deeplink will be opened when clicked on the link                | 0.1.0 |\n\n\n#### ClearCookieOptions\n\n| Prop      | Type                |\n| --------- | ------------------- |\n| **`url`** | \u003ccode\u003estring\u003c/code\u003e |\n\n\n#### HttpCookie\n\n| Prop        | Type                | Description              |\n| ----------- | ------------------- | ------------------------ |\n| **`url`**   | \u003ccode\u003estring\u003c/code\u003e | The URL of the cookie.   |\n| **`key`**   | \u003ccode\u003estring\u003c/code\u003e | The key of the cookie.   |\n| **`value`** | \u003ccode\u003estring\u003c/code\u003e | The value of the cookie. |\n\n\n#### GetCookieOptions\n\n| Prop                  | Type                 |\n| --------------------- | -------------------- |\n| **`url`**             | \u003ccode\u003estring\u003c/code\u003e  |\n| **`includeHttpOnly`** | \u003ccode\u003eboolean\u003c/code\u003e |\n\n\n#### OpenWebViewOptions\n\n| Prop                                   | Type                                                                                                                                                                   | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   | Default                                                    | Since  |\n| -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- | ------ |\n| **`url`**                              | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | Target URL to load.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |                                                            | 0.1.0  |\n| **`headers`**                          | \u003ccode\u003e\u003ca href=\"#headers\"\u003eHeaders\u003c/a\u003e\u003c/code\u003e                                                                                                                            | \u003ca href=\"#headers\"\u003eHeaders\u003c/a\u003e to send with the request.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |                                                            | 0.1.0  |\n| **`credentials`**                      | \u003ccode\u003e\u003ca href=\"#credentials\"\u003eCredentials\u003c/a\u003e\u003c/code\u003e                                                                                                                    | \u003ca href=\"#credentials\"\u003eCredentials\u003c/a\u003e to send with the request and all subsequent requests for the same host.                                                                                                                                                                                                                                                                                                                                                                                                                                |                                                            | 6.1.0  |\n| **`materialPicker`**                   | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | materialPicker: if true, uses Material Design theme for date and time pickers on Android. This improves the appearance of HTML date inputs to use modern Material Design UI instead of the old style pickers.                                                                                                                                                                                                                                                                                                                                 | \u003ccode\u003efalse\u003c/code\u003e                                         | 7.4.1  |\n| **`jsInterface`**                      |                                                                                                                                                                        | JavaScript Interface: The webview automatically injects a JavaScript interface providing: - `window.mobileApp.close()`: Closes the webview from JavaScript - `window.mobileApp.postMessage(obj)`: Sends a message to the app (listen via \"messageFromWebview\" event)                                                                                                                                                                                                                                                                          |                                                            | 6.10.0 |\n| **`shareDisclaimer`**                  | \u003ccode\u003e\u003ca href=\"#disclaimeroptions\"\u003eDisclaimerOptions\u003c/a\u003e\u003c/code\u003e                                                                                                        | Share options for the webview. When provided, shows a disclaimer dialog before sharing content. This is useful for: - Warning users about sharing sensitive information - Getting user consent before sharing - Explaining what will be shared - Complying with privacy regulations Note: shareSubject is required when using shareDisclaimer                                                                                                                                                                                                 |                                                            | 0.1.0  |\n| **`toolbarType`**                      | \u003ccode\u003e\u003ca href=\"#toolbartype\"\u003eToolBarType\u003c/a\u003e\u003c/code\u003e                                                                                                                    | Toolbar type determines the appearance and behavior of the browser's toolbar - \"activity\": Shows a simple toolbar with just a close button and share button - \"navigation\": Shows a full navigation toolbar with back/forward buttons - \"blank\": Shows no toolbar - \"\": Default toolbar with close button                                                                                                                                                                                                                                     | \u003ccode\u003eToolBarType.DEFAULT\u003c/code\u003e                           | 0.1.0  |\n| **`shareSubject`**                     | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | Subject text for sharing. Required when using shareDisclaimer. This text will be used as the subject line when sharing content.                                                                                                                                                                                                                                                                                                                                                                                                               |                                                            | 0.1.0  |\n| **`title`**                            | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | Title of the browser                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | \u003ccode\u003e'New Window'\u003c/code\u003e                                  | 0.1.0  |\n| **`backgroundColor`**                  | \u003ccode\u003e\u003ca href=\"#backgroundcolor\"\u003eBackgroundColor\u003c/a\u003e\u003c/code\u003e                                                                                                            | Background color of the browser                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               | \u003ccode\u003eBackgroundColor.BLACK\u003c/code\u003e                         | 0.1.0  |\n| **`activeNativeNavigationForWebview`** | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | If true, active the native navigation within the webview, Android only                                                                                                                                                                                                                                                                                                                                                                                                                                                                        | \u003ccode\u003efalse\u003c/code\u003e                                         |        |\n| **`disableGoBackOnNativeApplication`** | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | Disable the possibility to go back on native application, useful to force user to stay on the webview, Android only                                                                                                                                                                                                                                                                                                                                                                                                                           | \u003ccode\u003efalse\u003c/code\u003e                                         |        |\n| **`isPresentAfterPageLoad`**           | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | Open url in a new window fullscreen isPresentAfterPageLoad: if true, the browser will be presented after the page is loaded, if false, the browser will be presented immediately.                                                                                                                                                                                                                                                                                                                                                             | \u003ccode\u003efalse\u003c/code\u003e                                         | 0.1.0  |\n| **`isInspectable`**                    | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | Whether the website in the webview is inspectable or not, ios only                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | \u003ccode\u003efalse\u003c/code\u003e                                         |        |\n| **`isAnimated`**                       | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | Whether the webview opening is animated or not, ios only                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      | \u003ccode\u003etrue\u003c/code\u003e                                          |        |\n| **`showReloadButton`**                 | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | Shows a reload button that reloads the web page                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               | \u003ccode\u003efalse\u003c/code\u003e                                         | 1.0.15 |\n| **`closeModal`**                       | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | CloseModal: if true a confirm will be displayed when user clicks on close button, if false the browser will be closed immediately.                                                                                                                                                                                                                                                                                                                                                                                                            | \u003ccode\u003efalse\u003c/code\u003e                                         | 1.1.0  |\n| **`closeModalTitle`**                  | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | CloseModalTitle: title of the confirm when user clicks on close button                                                                                                                                                                                                                                                                                                                                                                                                                                                                        | \u003ccode\u003e'Close'\u003c/code\u003e                                       | 1.1.0  |\n| **`closeModalDescription`**            | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | CloseModalDescription: description of the confirm when user clicks on close button                                                                                                                                                                                                                                                                                                                                                                                                                                                            | \u003ccode\u003e'Are you sure you want to close this window?'\u003c/code\u003e | 1.1.0  |\n| **`closeModalOk`**                     | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | CloseModalOk: text of the confirm button when user clicks on close button                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | \u003ccode\u003e'Close'\u003c/code\u003e                                       | 1.1.0  |\n| **`closeModalCancel`**                 | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | CloseModalCancel: text of the cancel button when user clicks on close button                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | \u003ccode\u003e'Cancel'\u003c/code\u003e                                      | 1.1.0  |\n| **`visibleTitle`**                     | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | visibleTitle: if true the website title would be shown else shown empty                                                                                                                                                                                                                                                                                                                                                                                                                                                                       | \u003ccode\u003etrue\u003c/code\u003e                                          | 1.2.5  |\n| **`toolbarColor`**                     | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | toolbarColor: color of the toolbar in hex format                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              | \u003ccode\u003e'#ffffff'\u003c/code\u003e                                     | 1.2.5  |\n| **`toolbarTextColor`**                 | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | toolbarTextColor: color of the buttons and title in the toolbar in hex format When set, it overrides the automatic light/dark mode detection for text color                                                                                                                                                                                                                                                                                                                                                                                   | \u003ccode\u003ecalculated based on toolbarColor brightness\u003c/code\u003e   | 6.10.0 |\n| **`showArrow`**                        | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | showArrow: if true an arrow would be shown instead of cross for closing the window                                                                                                                                                                                                                                                                                                                                                                                                                                                            | \u003ccode\u003efalse\u003c/code\u003e                                         | 1.2.5  |\n| **`ignoreUntrustedSSLError`**          | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | ignoreUntrustedSSLError: if true, the webview will ignore untrusted SSL errors allowing the user to view the website.                                                                                                                                                                                                                                                                                                                                                                                                                         | \u003ccode\u003efalse\u003c/code\u003e                                         | 6.1.0  |\n| **`preShowScript`**                    | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | preShowScript: if isPresentAfterPageLoad is true and this variable is set the plugin will inject a script before showing the browser. This script will be run in an async context. The plugin will wait for the script to finish (max 10 seconds)                                                                                                                                                                                                                                                                                             |                                                            | 6.6.0  |\n| **`proxyRequests`**                    | \u003ccode\u003estring\u003c/code\u003e                                                                                                                                                    | proxyRequests is a regex expression. Please see [this pr](https://github.com/Cap-go/capacitor-inappbrowser/pull/222) for more info. (Android only)                                                                                                                                                                                                                                                                                                                                                                                            |                                                            | 6.9.0  |\n| **`buttonNearDone`**                   | \u003ccode\u003e{ ios: { iconType: 'sf-symbol' \\| 'asset'; icon: string; }; android: { iconType: 'asset' \\| 'vector'; icon: string; width?: number; height?: number; }; }\u003c/code\u003e | buttonNearDone allows for a creation of a custom button near the done/close button. The button is only shown when toolbarType is not \"activity\", \"navigation\", or \"blank\". For Android: - iconType must be \"asset\" - icon path should be in the public folder (e.g. \"monkey.svg\") - width and height are optional, defaults to 48dp - button is positioned at the end of toolbar with 8dp margin For iOS: - iconType can be \"sf-symbol\" or \"asset\" - for sf-symbol, icon should be the symbol name - for asset, icon should be the asset name |                                                            | 6.7.0  |\n| **`textZoom`**                         | \u003ccode\u003enumber\u003c/code\u003e                                                                                                                                                    | textZoom: sets the text zoom of the page in percent. Allows users to increase or decrease the text size for better readability.                                                                                                                                                                                                                                                                                                                                                                                                               | \u003ccode\u003e100\u003c/code\u003e                                           | 7.6.0  |\n| **`preventDeeplink`**                  | \u003ccode\u003eboolean\u003c/code\u003e                                                                                                                                                   | preventDeeplink: if true, the deeplink will not be opened, if false the deeplink will be opened when clicked on the link. on IOS each schema need to be added to info.plist file under LSApplicationQueriesSchemes when false to make it work.                                                                                                                                                                                                                                                                                                | \u003ccode\u003efalse\u003c/code\u003e                                         | 0.1.0  |\n\n\n#### Headers\n\n\n#### Credentials\n\n| Prop           | Type                |\n| -------------- | ------------------- |\n| **`username`** | \u003ccode\u003estring\u003c/code\u003e |\n| **`password`** | \u003ccode\u003estring\u003c/code\u003e |\n\n\n#### DisclaimerOptions\n\n| Prop             | Type                | Description                            | Default                |\n| ---------------- | ------------------- | -------------------------------------- | ---------------------- |\n| **`title`**      | \u003ccode\u003estring\u003c/code\u003e | Title of the disclaimer dialog         | \u003ccode\u003e\"Title\"\u003c/code\u003e   |\n| **`message`**    | \u003ccode\u003estring\u003c/code\u003e | Message shown in the disclaimer dialog | \u003ccode\u003e\"Message\"\u003c/code\u003e |\n| **`confirmBtn`** | \u003ccode\u003estring\u003c/code\u003e | Text for the confirm button            | \u003ccode\u003e\"Confirm\"\u003c/code\u003e |\n| **`cancelBtn`**  | \u003ccode\u003estring\u003c/code\u003e | Text for the cancel button             | \u003ccode\u003e\"Cancel\"\u003c/code\u003e  |\n\n\n#### PluginListenerHandle\n\n| Prop         | Type                                      |\n| ------------ | ----------------------------------------- |\n| **`remove`** | \u003ccode\u003e() =\u0026gt; Promise\u0026lt;void\u0026gt;\u003c/code\u003e |\n\n\n#### UrlEvent\n\n| Prop      | Type                | Description               | Since |\n| --------- | ------------------- | ------------------------- | ----- |\n| **`url`** | \u003ccode\u003estring\u003c/code\u003e | Emit when the url changes | 0.0.1 |\n\n\n#### BtnEvent\n\n| Prop      | Type                | Description                    | Since |\n| --------- | ------------------- | ------------------------------ | ----- |\n| **`url`** | \u003ccode\u003estring\u003c/code\u003e | Emit when a button is clicked. | 0.0.1 |\n\n\n### Type Aliases\n\n\n#### ClearCookieOptions\n\n\u003ccode\u003e\u003ca href=\"#omit\"\u003eOmit\u003c/a\u003e\u0026lt;\u003ca href=\"#httpcookie\"\u003eHttpCookie\u003c/a\u003e, 'key' | 'value'\u0026gt;\u003c/code\u003e\n\n\n#### Omit\n\nConstruct a type with the properties of T except for those in type K.\n\n\u003ccode\u003e\u003ca href=\"#pick\"\u003ePick\u003c/a\u003e\u0026lt;T, \u003ca href=\"#exclude\"\u003eExclude\u003c/a\u003e\u0026lt;keyof T, K\u0026gt;\u0026gt;\u003c/code\u003e\n\n\n#### Pick\n\nFrom T, pick a set of properties whose keys are in the union K\n\n\u003ccode\u003e{\r [P in K]: T[P];\r }\u003c/code\u003e\n\n\n#### Exclude\n\n\u003ca href=\"#exclude\"\u003eExclude\u003c/a\u003e from T those types that are assignable to U\n\n\u003ccode\u003eT extends U ? never : T\u003c/code\u003e\n\n\n#### Record\n\nConstruct a type with a set of properties K of type T\n\n\u003ccode\u003e{\r [P in K]: T;\r }\u003c/code\u003e\n\n\n#### GetCookieOptions\n\n\u003ccode\u003e\u003ca href=\"#omit\"\u003eOmit\u003c/a\u003e\u0026lt;\u003ca href=\"#httpcookie\"\u003eHttpCookie\u003c/a\u003e, 'key' | 'value'\u0026gt;\u003c/code\u003e\n\n\n#### UrlChangeListener\n\n\u003ccode\u003e(state: \u003ca href=\"#urlevent\"\u003eUrlEvent\u003c/a\u003e): void\u003c/code\u003e\n\n\n#### ButtonNearListener\n\n\u003ccode\u003e(state: object): void\u003c/code\u003e\n\n\n#### ConfirmBtnListener\n\n\u003ccode\u003e(state: \u003ca href=\"#btnevent\"\u003eBtnEvent\u003c/a\u003e): void\u003c/code\u003e\n\n\n### Enums\n\n\n#### ToolBarType\n\n| Members          | Value                     | Description                                                      | Since |\n| ---------------- | ------------------------- | ---------------------------------------------------------------- | ----- |\n| **`ACTIVITY`**   | \u003ccode\u003e\"activity\"\u003c/code\u003e   | Shows a simple toolbar with just a close button and share button | 0.1.0 |\n| **`COMPACT`**    | \u003ccode\u003e\"compact\"\u003c/code\u003e    | Shows a simple toolbar with just a close button                  | 7.6.8 |\n| **`NAVIGATION`** | \u003ccode\u003e\"navigation\"\u003c/code\u003e | Shows a full navigation toolbar with back/forward buttons        | 0.1.0 |\n| **`BLANK`**      | \u003ccode\u003e\"blank\"\u003c/code\u003e      | Shows no toolbar                                                 | 0.1.0 |\n\n\n#### BackgroundColor\n\n| Members     | Value                |\n| ----------- | -------------------- |\n| **`WHITE`** | \u003ccode\u003e\"white\"\u003c/code\u003e |\n| **`BLACK`** | \u003ccode\u003e\"black\"\u003c/code\u003e |\n\n\u003c/docgen-api\u003e\n\n**Credits**\n - [WKWebViewController](https://github.com/Meniny/WKWebViewController) - for iOS\n - [CapBrowser](https://github.com/gadapa-rakesh/CapBrowser) - For the base in capacitor v2\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCap-go%2Fcapacitor-inappbrowser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FCap-go%2Fcapacitor-inappbrowser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCap-go%2Fcapacitor-inappbrowser/lists"}