How to use the @capacitor/core.Plugins.Browser function in @capacitor/core

To help you get started, we’ve selected a few @capacitor/core examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ionic-team / capacitor / example / src / pages / browser / browser.ts View on Github external
constructor(public navCtrl: NavController, public navParams: NavParams) {
    Plugins.Browser.addListener('browserFinished', (info: any) => {
      console.log('Browser all done!');
    });
    Plugins.Browser.addListener('browserPageLoaded', (info: any) => {
      console.log('Browser page loaded!');
    });
    Plugins.Browser.prefetch({
      urls: ["https://ionicframework.com/"]
    });
  }
github ionic-team / capacitor / example / src / pages / browser / browser.ts View on Github external
browserOpen() {
    Plugins.Browser.open({
      url: 'https://ionicframework.com',
      toolbarColor: "#5A5DF5"
    });

    setTimeout(() => {
      Plugins.Browser.close();
    }, 5000);
  }
github osrs-tracker / osrs-tracker / src / app / features / home / components / osrs-news / osrs-news.component.ts View on Github external
openInBrowser(url: string): Promise {
    return Plugins.Browser.open({ url, toolbarColor: '#1e2023' });
  }
github osrs-tracker / osrs-tracker / src / app / features / grand-exchange / item-detail / item-detail.page.ts View on Github external
async openWiki(): Promise {
    const url = `https://oldschool.runescape.wiki/w/${this.item.name}`;
    Plugins.Browser.open({ url, toolbarColor: '#1e2023' });
  }
github osrs-tracker / osrs-tracker / src / app / features / app-news / app-news.page.ts View on Github external
el.onclick = (event: Event) => {
        event.preventDefault();
        Plugins.Browser.open({ url: el.href, toolbarColor: '#1e2023' });
      };
    });
github osrs-tracker / osrs-tracker / src / app / features / osrs-wiki / osrs-wiki.page.ts View on Github external
async openInBrowser(url: string): Promise {
    Plugins.Browser.open({ url, toolbarColor: '#1e2023' });
  }
}