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
My current thoughts are, if a derived observable throws an error, a separate stream should emit a value.
So if you had
class Foo {
@observable
bar() {
// something happens that causes an error
}
}
var myFoo = new Foo();
foo.bar // "baz" -> good value
foo.bar // causes an error for some reason
foo.errors.bar // this would emit the error
foo.bar // this is still "baz"
This could also be configured somehow for the whole class and also for each property
@error("propertyErrors")
class Foo {
@observable
bar() {
// something happens that causes an error
}
@observable({
error: "bazError"
})
baz() {
// something happens that causes an error
}
}
var myFoo = new Foo();
myFoo.propertyErrors.bar // this is the errors for bar
myFoo.bazError // this is the errors for baz
The text was updated successfully, but these errors were encountered:
My current thoughts are, if a derived observable throws an error, a separate stream should emit a value.
So if you had
This could also be configured somehow for the whole class and also for each property
The text was updated successfully, but these errors were encountered: