fix: configure pnpm to resolve dependency loading issues

- Add shamefully-hoist=true to .npmrc for proper dependency hoisting
- Configure pnpm peerDependencyRules to ignore missing sqlite3
- Fixes "Cannot read properties of undefined (reading 'prototype')" error
- This ensures chaite's bundled dependencies work correctly with pnpm

Co-authored-by: ikechan8370 <21212372+ikechan8370@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2025-11-22 04:37:16 +00:00
parent 4e2b4967b0
commit bc469ab019
2 changed files with 9 additions and 2 deletions

1
.npmrc
View file

@ -1,2 +1,3 @@
sharp_libvips_binary_host="https://registry.npmmirror.com/-/binary/sharp-libvips"
nodejieba_binary_host_mirror="https://npm.taobao.org/mirrors/nodejieba"
shamefully-hoist=true

View file

@ -17,5 +17,11 @@
"peerDependencies": {
"sqlite3": ">=5.1.6"
},
"pnpm": {}
"pnpm": {
"peerDependencyRules": {
"ignoreMissing": [
"sqlite3"
]
}
}
}