Skip to content

ModuleResolution Node16/NodeNext fails without extension starting on 5.5.0-dev.20240413 #58214

@Noriller

Description

@Noriller

🔎 Search Terms

moduleResolution node16 nodeNext import extension

🕗 Version & Regression Information

  • This changed between versions 5.5.0-dev.20240413 and 5.5.0-dev.20240415 (last one checked)

⏯ Playground Link

No response

💻 Code

type Something1 = typeof import('@some/package/path/to/file');
type Something2 = typeof import('@some/package/path/to/file.js');

🙁 Actual behavior

Something1 resolves to any
Something2 resolves to Something

🙂 Expected behavior

Something1 resolves to Something
Something2 resolves to Something

Additional information about the issue

This happens on the latest nightly versions and on moduleResolution Node16/NodeNext.

From what I could get, it started on 5.5.0-dev.20240413.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Not a DefectThis behavior is one of several equally-correct options

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions