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

191
Views
can't resolve module inside subdirectory typescript

The module arrayGenerator.ts lies inside a subfolder, it works fine for other modules(Array.ts) inside the parent folder. But when I add a new module Sorting.ts, it gives me can't resolve the error. There is inconsistency regarding the compilation. no Array.js in dist but it was working.. path is like this. and below is my tsconfig.json. I tried some configurations like change "src" to "src/**/*", but all don't work or the compiler turned down the changes.

dir
 - slices
  - dist 
  - Array.ts
  - Sorting.ts
  - bricks
    - arrayGenerator.ts

{
  "compilerOptions": {
    "target": "es5",
    "lib": [
      "dom",
      "dom.iterable",
      "esnext"
    ],
    "allowJs": true,
    "skipLibCheck": true,
    "esModuleInterop": true,
    "allowSyntheticDefaultImports": true,
    "strict": true,
    "forceConsistentCasingInFileNames": true,
    "noFallthroughCasesInSwitch": true,
    "module": "esnext",
    "moduleResolution": "node",
    "resolveJsonModule": true,
    "isolatedModules": true,
    "jsx": "react-jsx",
    "noEmit": true
  },
  "include": [
    "src"
  ]
}
about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

The issue disappeared after I transferred code to a new template.

about 4 years ago · Juan Pablo Isaza Report

0

I had a similar issue, and it went away after re-saving the files that caused errors. The problem is very reproducible when moving or renaming files. Seems like Webpack is not updating its cache.

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!