Skip to content

Should we suggest a means of tracking where a PWA was installed from? #19

Open
@aarongustafson

Description

@aarongustafson

Use case is disambiguation of the following:

  1. Casual browsing to the PWA
  2. Installed via the browser
  3. Installed from an app catalog/store

Based on what’s out there currently, the first item is already covered. Numbers 2 & 3 could be aggregated by testing the display value (via JS and CSS), but would not be distinguishable from one another. In order to truly distinguish those installation sources, it would require the developer to author at least two separate manifests that have a start_url with a unique query string parameter (e.g., /?installed=web, /?installed=store_name). While doable, this approach could get out of control quickly as developers create unique manifests for each app catalog/store.

To simplify things, we could piggyback on the existing referer header. Here’s what that might look like (all strings for presentation only):

  • Casual browsing to the PWA: no change to referer (standard browser behavior)
  • Installed via the browser (Edge): referer: "edge://apps"
  • Installed from an app catalog/store (Microsoft Store): referer: "store://www.microsoft.com/store/apps/windows"

This change in the behavior of referer could be limited to the initial navigation, which would make it quite similar to the query string approach in terms of analytics tracking.

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions