Skip to content

[Feature Request] Try jsconfig.json if no tsconfig.json is found when resolve.tsconfigPaths is set to true #23535

Description

@yangmingshan

Description

Vite only reads tsconfig.json when resolve.tsconfigPaths is set to true. It might be worth considering jsconfig.json as a fallback when no tsconfig.json is found. This would be more convenient for JS users.

Suggested solution

Search for tsconfig.json first. If it is not found, try falling back to jsconfig.json.

Alternative

A jsconfigPaths option?

Additional context

Reference: https://github.com/privatenumber/get-tsconfig

Validations

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions