update vite-plugin-inspect to latest version
When using vite-plugin-vue-devtools and vite-plugin-inspect at the same time there is no way to show module details since version bundled with the plugin here is too old (0.8.9) where we don't have woff2 files (bug fixed) and the css file referencing the fonts via absolute url /assets/fonts/.....
Removing the vite-plugin-inspect fix the problem.
For context, check https://github.com/antfu-collective/vite-plugin-inspect/issues/134 (reproduction there)
Alternatively we can add a note here in the docs: something like this https://github.com/antfu-collective/vite-plugin-inspect/pull/145#issue-2871093537
We locked vite-plugin-inspect to version 0.8.9 in devtools for compatibility with Vite versions below 6. Perhaps we should make it a peerDependencies instead. However, I'm not sure if there are any breaking API changes in the latest version of vite-plugin-inspect. Any suggestions?
Since the last release enables Vite 7, this dependency must be updated. as the current version supports up to Vite 6. Can't upgrade to latest release now as dependencies are conflicting.
Running into issues here as well:
npm warn ERESOLVE overriding peer dependency
npm warn While resolving: [email protected]
npm warn Found: [email protected]
npm warn node_modules/vite
npm warn dev vite@"^7.0.0" from the root project
npm warn 6 more (@tailwindcss/vite, @vitejs/plugin-vue, ...)
npm warn
npm warn Could not resolve dependency:
npm warn peer vite@"^3.1.0 || ^4.0.0 || ^5.0.0-0 || ^6.0.1" from [email protected]
npm warn node_modules/vite-plugin-vue-devtools/node_modules/vite-plugin-inspect
npm warn vite-plugin-inspect@"0.8.9" from [email protected]
npm warn node_modules/vite-plugin-vue-devtools
npm warn
npm warn Conflicting peer dependency: [email protected]
npm warn node_modules/vite
npm warn peer vite@"^3.1.0 || ^4.0.0 || ^5.0.0-0 || ^6.0.1" from [email protected]
npm warn node_modules/vite-plugin-vue-devtools/node_modules/vite-plugin-inspect
npm warn vite-plugin-inspect@"0.8.9" from [email protected]
npm warn node_modules/vite-plugin-vue-devtools
I worked around this by adding the following to my package.json:
"overrides": {
"vite-plugin-vue-devtools": {
"vite-plugin-inspect": "^11.3.0"
}
}
Via: https://stackoverflow.com/a/48524488
After doing so the peer dependency errors are gone and at first glance nothing seems broken. Obviously this only works if you don't need to support Vite versions below 6 as mentioned above.
@yannickincyberatlantis Nice, I'll override the vite-plugin-inspect module itself as NPM seems to ignore the nested override...IDK why, according to my NPM version and documentation it should work.
But this only fixes our own dependency issue, that still means that this repo uses a dependency that cannot handle Vite 7 while claiming to be able to work with Vite 7 themselves, imo this is a versioning boo-boo introduced by themselves when they pinned the dependency version a while back.
I agree with @svanschooten, I will also override the peer. That does not look like a permanent fix, though.
Be related to https://github.com/vuejs/devtools/issues/923