If we don't have a "device" e.g. it isn't an installed app we could instead use navigator.userAgent (with a similar test)