Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolver fails for relative paths #66

Closed
remcohaszing opened this issue Jan 9, 2021 · 1 comment
Closed

Resolver fails for relative paths #66

remcohaszing opened this issue Jan 9, 2021 · 1 comment

Comments

@remcohaszing
Copy link

I have the following tsconfig.json:

{
  "compilerOptions": {
    "baseUrl": ".",
    "lib": ["esnext"],
    "module": "commonjs",
    "noEmit": true,
    "noImplicitAny": true,
    "paths": {
      "axios-test-instance": ["index.ts"]
    },
    "strict": true,
    "target": "esnext"
  }
}

TypeScript 4.1 supports using relative paths without the baseUrl option. This means the following works with TypeScript now:

{
  "compilerOptions": {
    "lib": ["esnext"],
    "module": "commonjs",
    "noEmit": true,
    "noImplicitAny": true,
    "paths": {
      "axios-test-instance": ["./index.ts"]
    },
    "strict": true,
    "target": "esnext"
  }
}

However, this makes eslint-import-resolver-typescript unable to resolve the mapped paths.

@JounQin
Copy link
Collaborator

JounQin commented Feb 16, 2021

It should be related to tsconfig-paths.

@JounQin JounQin closed this as completed Feb 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants