Conversation
|
Install the latest version of pnpm add https://pkg.svelte.dev/@sveltejs/kit/c/0a2668a7d08eb94ee7f0c1c75fca61b4b75dafddOpen in Note This PR is from a fork. A maintainer must approve approve each commit before it can be built and installed. |
🦋 Changeset detectedLatest commit: 0a2668a The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
| test('ignores extensions that are not listed', () => { | ||
| write('hooks.server.py', ''); | ||
|
|
||
| expect(resolve_entry(join(source_dir, 'hooks.server'))).null; |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Organization UI (inherited) Review profile: QUIET Plan: Advanced Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
🔗 Linked repositories identifiedCodeRabbit considers these linked repositories for cross-repo context during reviews:
Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review. 📝 WalkthroughWalkthrough
Merge Risk: ⚪ Minimal · up to Module entry resolution now consistently honors configured extensions across Kit entry points, with matching documentation and resolver coverage. No merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
Warning Some tools did not complete. Review the errors below. 🔧 ESLint
packages/kit/src/exports/vite/public.d.tsESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox. Comment |
`resolve_entry` matched `/\.(js|ts)$/`, so `kit.moduleExtensions` was honoured by the router but nowhere else. A project that compiles another language to JavaScript could have route modules in that language, yet had to keep `src/hooks.server.js` as a shim re-exporting from the real file — and the same went for the param matchers, the service worker, the instrumentation file and `src/env`. `resolve_entry` now takes the list of extensions to accept, defaulting to `['.js', '.ts']` so nothing changes for anyone who does not set `moduleExtensions`, and every entry point that is a module passes `config.moduleExtensions`. `check_spelling` takes them too, so a misspelled `hooks.sever.py` is caught the same way `hooks.sever.js` is.
c36e857 to
0a2668a
Compare
resolve_entrymatched/\.(js|ts)$/, sokit.moduleExtensionswas honoured by the router but nowhere else. A project that compiles another language to JavaScript could have route modules in that language, yet had to keepsrc/hooks.server.jsas a shim re-exporting from the real file — and the same went for the param matchers, the service worker, the instrumentation file andsrc/env.resolve_entrynow takes the list of extensions to accept, defaulting to['.js', '.ts']so nothing changes for anyone who does not setmoduleExtensions, and every entry point that is a module passesconfig.moduleExtensions.check_spellingtakes them too, so a misspelledhooks.sever.pyis caught the same wayhooks.sever.jsis.