0

I have created a Chrome packaged app and when i execute the following line in command prompt, it launches that packaged app:

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --load-and-launch-app="chrome-app-path-goes-here"

How can I launch this Chrome app by clicking on a button in a html page? Any javascript or jQuery way of doing this?

adw
  • 269
  • 1
  • 3
  • 8

1 Answers1

1

Yes, it's possible.

Requirements:

  • specifically whitelisting the domain in the manifest
  • knowing the app's ID (you can pin it for development)
  • having the app already installed.

Take a look at externally_connectable: docs, example.

What you can do is to send a message to the app, which will wake up its Event page.
From there, you can open the app's window as usual.

Community
  • 1
  • 1
Xan
  • 74,770
  • 16
  • 179
  • 206