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
Hello guys, when I import a function from another package, it loses its type definition. The type is defined globally within that package. Other types work fine. How can I solve it?
It is necessary to say that I am just performing transition from yarn 1.22 to pnpm and this has worked with yarn just a commit prior.
Where apps/app-v2(on left) imports from packages/holograph(on right).
// edit
Furthermore, I noticed that declaring the type in an Ambient declarations file (interfaces.d.ts) works, but it is not picked up when contributing ambient declarations via declare global keyword.
// edit 2
I just reverted the commit back and after installing with yarn, the type is working again.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello guys, when I import a function from another package, it loses its type definition. The type is defined globally within that package. Other types work fine. How can I solve it?
It is necessary to say that I am just performing transition from yarn 1.22 to pnpm and this has worked with yarn just a commit prior.
pnpm-workspace.yaml
root
package.json
app-v2
tsconfig.json
Where
apps/app-v2
(on left) imports frompackages/holograph
(on right).// edit
Furthermore, I noticed that declaring the type in an Ambient declarations file (
interfaces.d.ts
) works, but it is not picked up when contributing ambient declarations viadeclare global
keyword.// edit 2
I just reverted the commit back and after installing with
yarn
, the type is working again.Beta Was this translation helpful? Give feedback.
All reactions