title: jsconfig.json paths for modules in node_modules
body: <p>I have following file structure:</p>
  <pre><code>project
  ├── process
  │   └── MyProjectLib
  │       └── process.js
  ├── node_modules
  │   └── MyModule
  │       └── process
  │           └── MyModuleLib
  │               └── process.js
  └── jsconfig.json
  </code></pre>
  <p>Content of process.js in MyModuleLib:</p>
  <pre><code>export function myModuleFunction()
  {
      return &quot;hallo&quot;;
  }
  </code></pre>
  <p>Content of process.js in MyProjectLib:</p>
  <pre><code>function myProjectFunction()
  {
      var x = myModuleFunction();
  
      return x + &quot; myModuleFunction&quot;;
  }
  </code></pre>
  <p>Now I need an import in MyProjectLib.process.js</p>
  <p>It has to be in this format (I cannot change it, this needs my application):</p>
  <pre><code>import { myModuleFunction } from &quot;MyModuleLib&quot;;
  </code></pre>
  <p>But currently it looks like</p>
  <pre><code>import { myModuleFunction } from &quot;MyModule/process/MyModuleLib/process&quot;;
  </code></pre>
  <p>My jsconfig.json:</p>
  <pre><code>{
      &quot;compilerOptions&quot;: {
        &quot;module&quot;: &quot;es6&quot;,      
        &quot;moduleResolution&quot;: &quot;node&quot;,
        &quot;baseUrl&quot;: &quot;.&quot;,
        &quot;allowSyntheticDefaultImports&quot;: true,
        &quot;checkJs&quot;: true,
        &quot;noEmit&quot;: true,
        &quot;removeComments&quot;: true,
        &quot;strict&quot;: false,
        &quot;paths&quot;: {
          &quot;*&quot;: [ &quot;MyModule/process/MyModuleLib/process&quot;]
        }
      },
      &quot;include&quot;: [&quot;**/*.js&quot;, &quot;node_modules/**/process/*/process.js&quot;],
  }
  </code></pre>
  <p>The content of node_modules cannnot be changed. I tried to modfiy it with &quot;paths&quot; but it doesn't work. How can I route the import so it looks like i want?</p>
  <p>In the best case the solution should not be specific to &quot;MyModule&quot;, though it should work with similar modules in the directory &quot;node_modules&quot;.</p>