Skip to content

Set TypeScript compiler's base/working directory #25430

Open
@slavafomin

Description

@slavafomin

It looks like TypeScript compiler resolves files relative to the location of the tsconfig.json file (however, I couldn't find anything about paths resolution in the official documentation).

Is there a way to specify an alternative base/working directory, which will be used for relative paths resolution?

I want to use a generic tsconfig.json file to compile multiple projects in various directories (one at a time).

P/S: I've created a question on StackOverflow first, but haven't received any attention there, so I've decided to ask here directly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    In DiscussionNot yet reached consensusSuggestionAn idea for TypeScript

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions