Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] 5.3.0 breaking typescript #507

Closed
JustFly1984 opened this issue Jan 15, 2020 · 11 comments
Closed

[bug] 5.3.0 breaking typescript #507

JustFly1984 opened this issue Jan 15, 2020 · 11 comments
Labels

Comments

@JustFly1984
Copy link

🐛 Bug Report

Screenshot 2020-01-15 04 47 48

reverting back to 5.2.1 helps.

node.js 13.3.0
yarn
TS 3.8.4

@JackCA
Copy link

JackCA commented Jan 15, 2020

I'm also seeing typescript related issues in 5.3.0, although I can't confirm that it's the same issue as @JustFly1984.

What I see is that draft is implicitly getting the any type, even though the passed in state object is correctly typed:

Screen Shot 2020-01-14 at 6 39 13 PM

@laozhu
Copy link

laozhu commented Jan 15, 2020

I have the same problem with draft any type error.

@pdemarino
Copy link

pdemarino commented Jan 15, 2020

Same.

FWIW, it appears that some files are missing (e.g., dist/types-external.ts).

Not sure if that's the root cause.

@ptgamr
Copy link

ptgamr commented Jan 15, 2020

Same for me, after upgrade:

Parameter 'draft' implicitly has an 'any' type.

@mweststrate
Copy link
Collaborator

@egoist Looks like an issue with bili, not exporting types for files that don't export any source code.

Pushed a temporarily workaround

@aleclarson
Copy link
Member

🎉 This issue has been resolved in version 5.3.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@gavrielco
Copy link

I'm still getting the same error with version 5.3.1

@mweststrate
Copy link
Collaborator

mweststrate commented Jan 15, 2020

Weird, the file is still absent in npm. Manually released, could you try in 5.3.2?

https://unpkg.com/browse/[email protected]/dist/

@egoist
Copy link
Contributor

egoist commented Jan 15, 2020

I tried building immer locally without @mweststrate 's fix and that file is also correctly built. 🤔

@mweststrate
Copy link
Collaborator

argh, for me it now appears as well, even on commit 747d268

@gavrielco
Copy link

5.3.2 works for me 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

9 participants