{"action":"closed","issue":{"url":"https://api.github.com/repos/Microsoft/TypeScript/issues/25677","repository_url":"https://api.github.com/repos/Microsoft/TypeScript","labels_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/25677/labels{/name}","comments_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/25677/comments","events_url":"https://api.github.com/repos/Microsoft/TypeScript/issues/25677/events","html_url":"https://github.com/Microsoft/TypeScript/issues/25677","id":341391770,"node_id":"MDU6SXNzdWUzNDEzOTE3NzA=","number":25677,"title":"Publishing to NPM while using the tsconfig paths?","user":{"login":"oleersoy","id":1163873,"node_id":"MDQ6VXNlcjExNjM4NzM=","avatar_url":"https://avatars3.githubusercontent.com/u/1163873?v=4","gravatar_id":"","url":"https://api.github.com/users/oleersoy","html_url":"https://github.com/oleersoy","followers_url":"https://api.github.com/users/oleersoy/followers","following_url":"https://api.github.com/users/oleersoy/following{/other_user}","gists_url":"https://api.github.com/users/oleersoy/gists{/gist_id}","starred_url":"https://api.github.com/users/oleersoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oleersoy/subscriptions","organizations_url":"https://api.github.com/users/oleersoy/orgs","repos_url":"https://api.github.com/users/oleersoy/repos","events_url":"https://api.github.com/users/oleersoy/events{/privacy}","received_events_url":"https://api.github.com/users/oleersoy/received_events","type":"User","site_admin":false},"labels":[{"id":117630923,"node_id":"MDU6TGFiZWwxMTc2MzA5MjM=","url":"https://api.github.com/repos/Microsoft/TypeScript/labels/Out%20of%20Scope","name":"Out of Scope","color":"556677","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2018-07-16T05:07:33Z","updated_at":"2018-07-30T16:23:09Z","closed_at":"2018-07-30T16:23:09Z","author_association":"NONE","body":"Hello - Hope it's OK that I ask this question here.  I first posted it to SO and have seen similar questions asked without answers.  This is the SO question:\r\n\r\nhttps://stackoverflow.com/questions/51353762/compiling-typescript-path-aliases-to-relative-paths-for-npm-publishing\r\n\r\nIn addition I created a small project with a directory structure like this:\r\n\r\n```\r\n├── package.json\r\n├── src\r\n│   ├── boo.ts\r\n│   └── foo\r\n│       └── foo.ts\r\n├── target\r\n│   ├── boo.d.ts\r\n│   ├── boo.js\r\n│   └── foo\r\n│       ├── foo.d.ts\r\n│       └── foo.js\r\n└── tsconfig.json\r\n\r\nI setup the `baseUrl` and `paths` option like this:\r\n\r\n```\r\n    \"baseUrl\": \"./\",\r\n    \"paths\": {\r\n        \"@fireflysemantics/*\": [ \"src/*\" ]\r\n    },\r\n``` \r\n\r\nIn this case `boo` imports `foo` and when compiled the import looks like this:\r\n\r\n```\r\n\"use strict\";\r\nexports.__esModule = true;\r\nvar foo_1 = require(\"@fireflysemantics/foo/foo\");\r\nfunction boo() {\r\n    console.log(\"The boo is loose\");\r\n    foo_1.foo();\r\n}\r\nexports.boo = boo;\r\n```\r\n\r\nSo as you can see the `require` is still importing from the @fireflysemantics alias defined in the `tsconfig`.  However when published to NPM, node does not necessarily know where that is.  Thoughts?"}}
{"actor":{"display_login":"typescript-bot"}}