Skip to content

Rest 1/2 of Disable dynamic import wrapper __vite__injectQuery #16678

@b5414

Description

@b5414

Description

Reopen #16241 issue, because only 1/2 is solved for me / for my user case..

The problem is gone but only when I'm running npm run build, and the build version is going good (Thanks @bluwy), but if I running the same code but usings npm run dev (renamed to start in my sample project, which attached below)

Suggested solution

In both cases, vite should skip adding the compiler wrapper (__vite__injectQuery) if this is indicated by a special comment:

  • /* @vite-ignore */

Alternative

undo #16556 (ha ha)

Additional context

Repo: https://github.com/b5414/sample // attention to src\rendered\assets\background_modules.js:21

To see the issue, just open the console (ctrl + shift + i or f12) of opened google dot com window by extension with S icon

  • if you running build - you will see: test info: <Module>
  • if you running start - you will see: test err: bla bla bla __vite__injectQuery undefined

Validations

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions