You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
✓ Ready in 679ms
⨯ src/i18n/routing.ts (8:24) @ [project]/src/i18n/routing.ts [middleware] (ecmascript)
⨯ Error: defineRouting is not defined
at <unknown> ([project]/src/i18n/routing.ts [middleware] (ecmascript) (./src/i18n/routing.ts:8:24)
at <unknown> (./[turbopack]/browser/runtime/base/dev-base.ts:205:21)
at runModuleExecutionHooks (./[turbopack]/browser/runtime/base/dev-base.ts:264:5)
at instantiateModule (./[turbopack]/browser/runtime/base/dev-base.ts:203:5)
at getOrInstantiateModuleFromParent (./[turbopack]/browser/runtime/base/dev-base.ts:132:10)
at esmImport (./[turbopack]/shared/runtime-utils.ts:214:18)
at <unknown> ([project]/src/middleware.ts [middleware] (ecmascript) (./src/middleware.ts:3:1)
at <unknown> (./[turbopack]/browser/runtime/base/dev-base.ts:205:21)
at runModuleExecutionHooks (./[turbopack]/browser/runtime/base/dev-base.ts:264:5)
at instantiateModule (./[turbopack]/browser/runtime/base/dev-base.ts:203:5) {
digest: undefined
}
6 | export const locales: LocaleType[] = ['fr', 'en', 'es', 'it', 'nl', 'de']
7 |
> 8 | export const routing = defineRouting({
| ^
9 | // A list of all locales that are supported
10 | locales: locales,
11 |
✓ Compiled /_error in 401ms
GET / 404 in 2ms
○ Compiling /_not-found/page ...
✓ Compiled /_not-found/page in 701ms
⨯ src/i18n/routing.ts (8:24) @ [project]/src/i18n/routing.ts [middleware] (ecmascript)
⨯ Error: defineRouting is not defined
at <unknown> ([project]/src/i18n/routing.ts [middleware] (ecmascript) (./src/i18n/routing.ts:8:24)
at <unknown> (./[turbopack]/browser/runtime/base/dev-base.ts:205:21)
at runModuleExecutionHooks (./[turbopack]/browser/runtime/base/dev-base.ts:264:5)
at instantiateModule (./[turbopack]/browser/runtime/base/dev-base.ts:203:5)
at getOrInstantiateModuleFromParent (./[turbopack]/browser/runtime/base/dev-base.ts:132:10)
at esmImport (./[turbopack]/shared/runtime-utils.ts:214:18)
at <unknown> ([project]/src/middleware.ts [middleware] (ecmascript) (./src/middleware.ts:3:1)
at <unknown> (./[turbopack]/browser/runtime/base/dev-base.ts:205:21)
at runModuleExecutionHooks (./[turbopack]/browser/runtime/base/dev-base.ts:264:5)
at instantiateModule (./[turbopack]/browser/runtime/base/dev-base.ts:203:5) {
digest: undefined
}
6 | export const locales: LocaleType[] = ['fr', 'en', 'es', 'it', 'nl', 'de']
7 |
> 8 | export const routing = defineRouting({
| ^
9 | // A list of all locales that are supported
10 | locales: locales,
11 |
GET /en 404 in 2ms
Current vs. Expected behavior
This error doesn't exists without --turbo and the project run as expected.
Also after a long debugging session to find where this came from I found that this line in my tsconfig.json was causing it:
"paths": {"*": ["types/*.d.ts"]}
Provide environment information
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 23.6.0: Mon Jul 29 21:13:04 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T6020
Available memory (MB): 16384
Available CPU cores: 10
Binaries:
Node: 20.18.0
npm: 10.8.2
Yarn: N/A
pnpm: 9.12.1
Relevant Packages:
next: 15.0.2 // Latest available version is detected (15.0.2).
eslint-config-next: N/A
react: 19.0.0-rc.0
react-dom: 19.0.0-rc.0
typescript: 5.6.3
Next.js Config:
output: N/A
-----
I also have the exact same bug on a my laptop running Ubuntu 22 and my intel Mac so I don't think the platform matters
Which area(s) are affected? (Select all that apply)
Turbopack
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
No response
The text was updated successfully, but these errors were encountered:
Link to the code that reproduces this issue
https://github.com/Yohannfra/turbo-bug-reproduction-repo
To Reproduce
You will see this error message
Current vs. Expected behavior
This error doesn't exists without --turbo and the project run as expected.
Also after a long debugging session to find where this came from I found that this line in my tsconfig.json was causing it:
Provide environment information
Which area(s) are affected? (Select all that apply)
Turbopack
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
No response
The text was updated successfully, but these errors were encountered: