Title: With project references, some cross-package imports of inferred types are emitted with relative paths · Issue #42349 · microsoft/TypeScript · GitHub
Open Graph Title: With project references, some cross-package imports of inferred types are emitted with relative paths · Issue #42349 · microsoft/TypeScript
X Title: With project references, some cross-package imports of inferred types are emitted with relative paths · Issue #42349 · microsoft/TypeScript
Description: Bug Report Repro: https://github.com/eps1lon/ts-monorepo-type-import-paths 🔎 Search Terms I was asked to open this as a new issue: #39117 (comment) 🕗 Version & Regression Information This is the behavior in every version I tried, and I r...
Open Graph Description: Bug Report Repro: https://github.com/eps1lon/ts-monorepo-type-import-paths 🔎 Search Terms I was asked to open this as a new issue: #39117 (comment) 🕗 Version & Regression Information This is the be...
X Description: Bug Report Repro: https://github.com/eps1lon/ts-monorepo-type-import-paths 🔎 Search Terms I was asked to open this as a new issue: #39117 (comment) 🕗 Version & Regression Information This is th...
Opengraph URL: https://github.com/microsoft/TypeScript/issues/42349
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"With project references, some cross-package imports of inferred types are emitted with relative paths","articleBody":"# Bug Report\r\n\r\nRepro: https://github.com/eps1lon/ts-monorepo-type-import-paths\r\n\r\n### 🔎 Search Terms\r\n\r\nI was asked to open this as a new issue: https://github.com/microsoft/TypeScript/issues/39117#issuecomment-760470118\r\n\r\n### 🕗 Version & Regression Information\r\n\r\n- This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________\r\n\r\n### ⏯ Playground Link\r\n\r\nUnable to do this in the playground\r\n\r\n### 💻 Code\r\n\r\nSee https://github.com/eps1lon/ts-monorepo-type-import-paths\r\n```tsx\r\n// ArrowLeft.tsx\r\n\r\nimport * as React from \"react\";\r\nimport { createSvgIcon } from \"@material-ui/core/utils\";\r\n\r\nexport default createSvgIcon(\r\n \u003cpath d=\"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z\" />,\r\n \"ArrowLeft\"\r\n);\r\n\r\n// @material-ui/core/utils.d.ts\r\n\r\nimport * as React from \"react\";\r\nimport SvgIcon from \"./SvgIcon\";\r\n\r\nexport function createSvgIcon(\r\n path: React.ReactNode,\r\n displayName: string\r\n): typeof SvgIcon;\r\n\r\n// @material-ui/core/SvgIcon.d.ts\r\n\r\nimport * as React from \"react\";\r\nimport { StyledComponentProps } from \"@material-ui/styles\";\r\n\r\nexport interface SvgIconProps extends StyledComponentProps\u003c\"root\"> {\r\n children?: React.ReactNode;\r\n}\r\n\r\ndeclare const SvgIcon: React.JSXElementConstructor\u003cSvgIconProps>;\r\nexport default SvgIcon;\r\n\r\n// @material-ui/styles/index.d.ts\r\nexport interface StyledComponentProps\u003cClassKey extends string> {\r\n classes?: Record\u003cClassKey, string>;\r\n}\r\n``` \r\n\r\n### 🙁 Actual behavior\r\n\r\nGenerated `ArrowLeft.d.ts`\r\n```ts\r\nimport * as React from \"react\";\r\ndeclare const _default: React.JSXElementConstructor\u003cimport(\"../../core/src/SvgIcon\").SvgIconProps>;\r\nexport default _default;\r\n//# sourceMappingURL=ArrowLeft.d.ts.map\r\n```\r\n\r\n### 🙂 Expected behavior\r\n\r\n```ts\r\nimport * as React from \"react\";\r\ndeclare const _default: React.JSXElementConstructor\u003cimport(\"@material-ui/core/SvgIcon\").SvgIconProps>;\r\nexport default _default;\r\n//# sourceMappingURL=ArrowLeft.d.ts.map\r\n```\r\n","author":{"url":"https://github.com/eps1lon","@type":"Person","name":"eps1lon"},"datePublished":"2021-01-14T22:27:31Z","url":"https://github.com/microsoft/TypeScript/issues/42349"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:919038e9-13ed-d569-6dd1-66797f5ccfd9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B49C:17FB7:215FB97:2A57935:6B01AE99 |
| html-safe-nonce | 1c23e076b238f11b777c3cc5f05946645e910dbdae23ec2b86e9fe6ec8be0612 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNDlDOjE3RkI3OjIxNUZCOTc6MkE1NzkzNTo2QjAxQUU5OSIsInZpc2l0b3JfaWQiOiI2ODA5NTkzNzgyNTczNTc1ODMzIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 569f58482fa1cc922ac73b0a57936bcec71dfe98063e52cff8003b9eae514860 |
| hovercard-subject-tag | issue:786385716 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/TypeScript/42349/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e66466308f21e3aaadb2f5e1ce8b070a7975806d553a00c95c642d4915266286/microsoft/TypeScript/issues/42349 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e66466308f21e3aaadb2f5e1ce8b070a7975806d553a00c95c642d4915266286/microsoft/TypeScript/issues/42349 |
| og:image:alt | Bug Report Repro: https://github.com/eps1lon/ts-monorepo-type-import-paths 🔎 Search Terms I was asked to open this as a new issue: #39117 (comment) 🕗 Version & Regression Information This is the be... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | eps1lon |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/microsoft/TypeScript git https://github.com/microsoft/TypeScript.git |
| octolytics-dimension-user_id | 6154722 |
| octolytics-dimension-user_login | microsoft |
| octolytics-dimension-repository_id | 20929025 |
| octolytics-dimension-repository_nwo | microsoft/TypeScript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 20929025 |
| octolytics-dimension-repository_network_root_nwo | microsoft/TypeScript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width