core icon indicating copy to clipboard operation
core copied to clipboard

NodeNext ModuleResolution type issue

Open TSMI235 opened this issue 2 months ago • 1 comments

Describe the bug

We are seeing type issues when importing module-federation packages when our tsconfig uses moduleResolution of NodeNext. As far as I can tell this PR should have fixed it, but I'm seeing the same issue in my example.

Image

The reproduction repo is a simple pnpm based package, where the index files tries to import something from module-federation, while the tsconfig uses NodeNext, and you can see the type issue arise. If you switch the module and moduleResolution back to ESNext and Bundler the issue goes away.

Reproduction

https://github.com/TSMI235/ModuleFederation-NodeNext

Used Package Manager

pnpm

System Info

System:
    OS: macOS 15.6.1
    CPU: (12) arm64 Apple M2 Pro
    Memory: 110.69 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.16.0 -
    Yarn: 4.5.1 - 
    npm: 10.8.1 - 
    bun: 1.2.16 - 
    Deno: 2.5.6 - 
  Browsers:
    Chrome: 142.0.7444.135
    Safari: 26.1

Validations

TSMI235 avatar Nov 13 '25 16:11 TSMI235