Skip to content

[NEXT-1281] Support moduleResolution bundler in tsconfig.json #47858

Closed
@joshuajaco

Description

@joshuajaco

Verify canary release

  • I verified that the issue exists in the latest Next.js canary release

Provide environment information

Operating System:
      Platform: darwin
      Arch: arm64
      Version: Darwin Kernel Version 21.5.0: Tue Apr 26 21:08:29 PDT 2022; root:xnu-8020.121.3~4/RELEASE_ARM64_T8101
    Binaries:
      Node: 18.4.0
      npm: 8.12.1
      Yarn: 1.22.19
      pnpm: 7.2.1
    Relevant packages:
      next: 13.2.5-canary.28
      eslint-config-next: 13.2.4
      react: 18.2.0
      react-dom: 18.2.0

Which area(s) of Next.js are affected? (leave empty if unsure)

TypeScript

Link to the code that reproduces this issue

https://codesandbox.io/p/sandbox/relaxed-tess-ylwq9s?file=%2Ftsconfig.json&selection=%5B%7B%22endColumn%22%3A55%2C%22endLineNumber%22%3A18%2C%22startColumn%22%3A55%2C%22startLineNumber%22%3A18%7D%5D

To Reproduce

Set compilerOptions.moduleResolution to bundler in tsconfig.json

Describe the Bug

When setting the moduleResolution to bundler in tsconfig.json it will be reset to node when running next build.

Expected Behavior

It should allow bundler as it has been added in typescript@5

Which browser are you using? (if relevant)

No response

How are you deploying your application? (if relevant)

No response

NEXT-1281

Metadata

Metadata

Assignees

Labels

TypeScriptRelated to types with Next.js.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions