You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is the behavior in every version I tried (4.1.3, 4.2.0-dev.20201230), and I reviewed the FAQ for entries about: everything (could not find relevant entries)
Generated declaration file imports types via relative path ("../../styles/src").
This path is invalid once published to npm. I was under the impression the paths does not apply any rewrites (source: #25677 (comment))
This is the actual return type of createStyles. TypeScript should never inline types from libaries we import. Otherwise we need to re-build and publish everytime a dependent library changes their types.
The text was updated successfully, but these errors were encountered:
I believe this is a definite duplicate of #39117 (which was pointed out to be a probable duplicate of #38111). Does that seem like the same problem @eps1lon?
I believe this is a definite duplicate of #39117 (which was pointed out to be a probably duplicate of #38111). Does that seem like the same problem @eps1lon?
Definitely! Thanks for the pointers especially since they contain potential workarounds.
Bug Report
Originally reported in mui/material-ui#24112
🔎 Search Terms
declaration file relative import
Possibly related: #38111, #39695, #36763, #18311
🕗 Version & Regression Information
⏯ Playground Link
Not applicable but I have a cloneable repro: https://github.com/eps1lon/ts-monorepo-type-import-paths
💻 Code
🙁 Actual behavior
Generated declaration file imports types via relative path (
"../../styles/src"
).This path is invalid once published to npm. I was under the impression the
paths
does not apply any rewrites (source: #25677 (comment))🙂 Expected behavior (minimum viable)
Types are imported with the original identifier (
"@material-ui/styles"
). Otherwise they're unreachable once installed.ideal expected behavior
This is the actual return type of
createStyles
. TypeScript should never inline types from libaries we import. Otherwise we need to re-build and publish everytime a dependent library changes their types.The text was updated successfully, but these errors were encountered: