-
Notifications
You must be signed in to change notification settings - Fork 125
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
Object.fromEntries #78
Comments
Object.entries won't be added - check the readme! But Object.fromEntries does seem to make sense - could you reduce the scope of this issue and rewrite the description? Or feel free to create a new issue. |
@mattpocock Sorry, didn't see that--updated the issue. I can send a PR to add this if you think it would be a good feature |
Let's leave this issue around to see if folks start screaming for it - off the top of my head it feels like a cool feature, but not an essential one. |
This comment was marked as off-topic.
This comment was marked as off-topic.
@akellbl4 Could you create a different issue? As it's unrelated to the current issue. |
Moving my example with |
@akellbl4 My bad! Thanks for your patience. |
I was looking for this also, but that example implementation doesn't seem to work for all cases. Given the input type I suppose they could all be marked as possibly undefined instead, but I don't know if that's what we'd want either |
I think the right way to deal with this would be |
Hey, I'm a fan of your YouTube videos and I'm excited to start using
ts-reset
in my projects.One feature I would really appreciate would be better typing for the
Object
constructor methodObject.fromEntries
:I found an implementation at this blog post:
Here's a playground link for the implementation: TS Playground Link
I'd be glad to write up a PR if you think this is worth adding.
The text was updated successfully, but these errors were encountered: