Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

91
Views
Import from node_modules without ../

When I auto import a file from node modules I want it to be like

import ComponentX from "@package/folder"

Instead I get something like

import ComponentX from "../../../node_modules/@package/folder/index"

My jsconfig.json looks like this

{
  "compileroptions": {
    "module": "es6",
    "target": "es6",
    "baseurl": "src"
  },
  "include": ["src"],
  "exclude": ["node_modules"]
}

I use emacs with lsp and ts-server.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

i hope this is gonna give you some insight,

"baseurl" : "src" mean the base path starting point is in the dir /scr,

so try change the base path to the root of your app,

change your baseurl to -> "baseurl" : "."

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!