mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-22 01:35:35 +00:00
d252be35ef
Differential Revision: https://phabricator.services.mozilla.com/D13207 --HG-- extra : moz-landing-system : lando
16 lines
440 B
HTML
16 lines
440 B
HTML
<meta charset=utf-8>
|
|
<script>
|
|
"use strict";
|
|
window.addEventListener("appinstalled", () => {
|
|
document
|
|
.querySelector("#output")
|
|
.innerHTML = "event received!";
|
|
// Send a custom event back to the browser
|
|
// to acknowledge that we got this
|
|
const detail = { result: true };
|
|
const ev = new CustomEvent("dom.manifest.onappinstalled", { detail });
|
|
document.dispatchEvent(ev);
|
|
});
|
|
</script>
|
|
<h1 id=output>waiting for event</h1>
|