Skip to content

Only installable on 1 domain #47

Open
@bilogic

Description

@bilogic
  1. I build the same set of vitepress files and host them on 2 domains (a.com and b.com)
  2. In config.ts, I tried to check domain and only call withPwa(...) if on a.com, but PWA still installable on both a.com and b.com
const expectedDomain = "a.com";
if (window.location.hostname == expectedDomain) {
    console.log("Installable because", window.location.hostname);
    final = withPwa(final);
} else console.log("Not installable because", window.location.hostname);
  1. Possible to make only PWA show install button only on a.com?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions