Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

264
Vistas
Vscode Path Intellisense not working with jsconfig.json (next js)

My project structure is like this:

jsconfig.json
next.config.json
components
   |_atoms
       |_Button.jsx
       |_Button.module.scss
       |_...
   |_...
...

and inside the jsconfig.json, I have this:

{
   "compilerOptions": {
      "baseUrl": ".",
      "paths": {
         "@/components/*": ["components/*"]
      }
   },

   "include": ["components/**/*", "api/**/*", "data/**/*", "pages/**/*", "utils/**/*"]
}

Next.js correctly imports the components and it's working, but on the developing side, autocomplete isn't working anymore!

for example, all of these import statements are working like a charm, but I manually wrote the path and autocomplete didn't help:

import Button from "components/atoms/Button";    //works
import Button from "@/components/atoms/Button";  //works
import Button from "../components/atoms/Button"; //works if the relative path is correct
import styles from "./Button.module.scss";       //works inside Button.jsx

So there's no problem with next js, but Path Intellisense isn't suggesting filenames anymore.
I renamed jsconfig.json to something else (to disable it) and this time, Path Intellisense works correctly, but next js can't import components.

How can I benefit from both? I want to have absolute imports and also use Path Intellisense.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda