davestewart / alias-hq

The end-to-end solution for configuring, refactoring, maintaining and using path aliases
https://davestewart.co.uk/projects/open-source/alias-hq/
MIT License
333 stars 12 forks source link

Aliases to a node module are mapped as relative to base path #53

Open NickBolles opened 2 years ago

NickBolles commented 2 years ago

tsconfig.json

    "baseUrl": "./src/js/"
    ...
      "handlebars": ["handlebars/runtime"],

output of hq.get('webpack')

  handlebars: '/Users/nick.bolles/Code/repo/src/js/handlebars/runtime',

this should stay as

  handlebars: 'handlebars/runtime',

it looks like setting the value to "handlebars": ["../../node_modules/handlebars/runtime"], in the tsconfig works, but that's not ideal.

davestewart commented 2 years ago

Hi NIck,

In essence, you're saying that Alias is not using the correct Node path resolution mechanism to resolve packages.

Sorry about this, I will look into it!