Skip to content

Add warning for dev + --mode production usage in vite-plugin-monkey #278

Description

@kaixinol

When using vite-plugin-monkey, running:

pnpm dev --mode production

can cause runtime issues such as:

  • [vite-plugin-monkey] not found monkeyWindow
  • GM_getValue is not a function

Although this is valid in Vite, it breaks the dev server + userscript bridge in vite-plugin-monkey.

It would be helpful to show a warning when detecting serve + production mode, e.g.:

⚠️ Avoid using `dev` with `--mode production`. Please use:
  • pnpm dev (development)
  • pnpm build (production)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions