-
Notifications
You must be signed in to change notification settings - Fork 463
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
Support empty string as a valid key in a Js.t object #3494
Comments
how do you access it in this case? |
In this use case I don't need to read the value. The object is only used to configure xstate. But I understand the dilemma so if this is too much of an edge you can close this. If anyone else stumbles on this, a workaround suggested was to use
|
We should at least provide a better error message |
moved to reasonml/reason#2387 |
The work around looks reasonable given this is a corner case |
@bobzhang should we allow this since object access syntax is now |
Defining a Js.t object such as
let obj = {"": someValue};
throws the following for me:I encountered the problem while trying to define an xstate transient transition which gives special meaning to the empty string key.
Side note: Putting the Js.t example above on the "Try Reason" website currently causes the site to completely crash.
The text was updated successfully, but these errors were encountered: