🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

typescript-plugin-tsconfig-paths

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

typescript-plugin-tsconfig-paths

A typescript language service plugin that allows typescript paths to be used with all extensions.

1.0.3
unpublished
latest
Source
npm
Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

typescript-plugin-tsconfig-paths

A typescript language service plugin that allows typescript paths to be used with all extensions.

Before:

scr-2

After:

scr-2

Table of contents

About this plugin

A typescript language service plugin that allows all extensions to use typescript paths. created because Typescript only implemented Tsconfig paths for typescript files only.

Note this plugin works within tsserver, it does not work within tsc and requires a separate alias setting in a bundler such as Webpack!

Installation

To install with npm:
npm install -D typescript-plugin-tsconfig-paths

To install with yarn;

yarn add -D typescript-plugin-tsconfig-paths

Once installed, add this plugin to your tsconfig.json:

{
    "compilerOptions": {
        "plugins": [{ "name": "typescript-plugin-tsconfig-paths" }]
    }
}

Options

OptionDefault valueDescription
extensions[".ts", ".tsx"]If a module does not have an extension, it will automatically attempt to add one, starting with the previous element.

Visual Studio Code

To activate this plugin in Visual Studio Code, put the following in .vscode/settings.json to change the behavior so that Vscode uses the Typescript of the workspace.
{
    "typescript.tsdk": "node_modules/typescript/lib"
}

Keywords

typescript

FAQs

Package last updated on 27 Apr 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts