What is the reason error property is boolean?
See original GitHub issueas opposed to an instance of Error
object. Boolean flag is vague. It just says what the error is and does not standardise the method of getting error description. Docs say that payload
by convention should be an Error
object.
Issue Analytics
- State:
- Created 8 years ago
- Comments:19
Top Results From Across the Web
Unknown boolean property: " + fieldName + " - Opster
A detailed guide on how to resolve errors related to "Unknown boolean property: " + fieldName + ""
Read more >why does accessing a property of a boolean value not throw ...
It's because false itself is an object, while undefined isn't. Variable is undefined if it wasn't assigned a value yet, like foo2 in...
Read more >Solving the Boolean Identity Crisis: Part 3 | Programming Elm
In this post, you learned that boolean properties can cause invalid state configurations, which create bugs that the compiler can't catch.
Read more >Error thrown. Attempt to modify property “response” on bool?
I received a critical error email form WordPress earlier today. Since WordPress 5.2 there is a built-in feature that detects when a plugin...
Read more >Boolean in custom policy give invalid type error
I had the same error caused by setting the wrong data type when creating the User attribute in the Azure portal ( ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The error design of Flux Standard Actions is completely unworkable for us; we’ve decided to not use Flux Standard Actions for that reason.
I think the original intent of adding
error
as a boolean property can be deduced from the example in the readme.There are no redundancies in this example.
Due to the way people use Redux, though, it starts to get redundant.
Perhaps the correct approach would be to separate app concerns from asynchronous concerns and instead of doing
request -> success | failure
, it’s better to dorequest -> success (triggers action<foo>) | failure (triggers error<foo>)
, whereaction<foo>
is equivalent to{ type: 'foo' }
anderror<foo>
is equivalent to{ type: 'foo', error: true }
with their respective payloads.The only issue this brings are optimistic updates. This could be solved, though, by triggering actions that queue the change when the request is made and then committing when it succeeds or reverting if it fails.