Repository navigation
fix: use one-arg import.meta.resolve for Bun compatibility - #2607
Conversation
Bun's two-arg import.meta.resolve(specifier, parent) fails for bare package names (Cannot find package 'wxt' / '@wxt-dev/…'). One-arg resolve works on both Bun and Node, so WXT CLI can run under bun --bun / bunx --bun.
✅ Deploy Preview for creative-fairy-df92c4 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Companion Bun issue for the two-arg |
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
Co-authored-by: Aaron <aaronklinker1@gmail.com>
import.meta.resolve for Bun compatibility
@wxt-dev/analytics
@wxt-dev/auto-icons
@wxt-dev/browser
@wxt-dev/i18n
@wxt-dev/is-background
@wxt-dev/module-react
@wxt-dev/module-solid
@wxt-dev/module-svelte
@wxt-dev/module-vue
@wxt-dev/runner
@wxt-dev/storage
@wxt-dev/unocss
@wxt-dev/webextension-polyfill
wxt
commit: |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2607 +/- ##
==========================================
- Coverage 79.63% 79.52% -0.11%
==========================================
Files 138 138
Lines 4114 4113 -1
Branches 943 943
==========================================
- Hits 3276 3271 -5
- Misses 740 743 +3
- Partials 98 99 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Thanks for helping make WXT better! |
Summary
import.meta.resolve(specifier, parent)fails for bare package names (Cannot find package 'wxt'when resolving from inside the package, and the same for WXT modules with a synthetic…/index.jsparent).resolveWxtModuleDirandresolveWxtUserModulesto one-argimport.meta.resolve, which works on both Bun and Node.bunx --bun wxt/bun --bunrun the WXT CLI (verified: HMR + production build).Related
import.meta.resolvepackage-name failures.Test plan
bunx --bun wxt --helpin a project that depends onwxtbunx --bun wxt(dev) starts withoutCannot find package 'wxt'@wxt-dev/unocss(or othermodules:) still loads modules under Bun and Nodenpx wxt/node …/wxt.mjsstill works