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
Doing a simple modification of the dashboard example to add a second field makes the 'fetch data' button break completely, with no error in the compilation or in console:
I changed data.json to:
{
"value": 123,
"foo": "bar"
}
and struct Status to:
struct Status {
value: u32,
foo: String
}
(and also updated the websocket update function to match, but i don't think that matters.)
Is there something else I need to do?
The text was updated successfully, but these errors were encountered:
Actually this seems to be working now, I'm not sure what the issue was. But I would like some better documentation/error handling, because it seems to drop any kind of deserialization errors on the floor as is.
Thank you for the feedback! I think the dashboard example is a bit confusing. It uses the same type for everything: web-request, ws-request, ws-response. serde follows the type declaration in deserialization strictly. If you change any field in Status type it have to be changed everywhere (in data.json file and in websocket interaction). I've fixed it with #72 to make this example more friendly.
Doing a simple modification of the dashboard example to add a second field makes the 'fetch data' button break completely, with no error in the compilation or in console:
I changed data.json to:
{
"value": 123,
"foo": "bar"
}
and struct Status to:
struct Status {
value: u32,
foo: String
}
(and also updated the websocket update function to match, but i don't think that matters.)
Is there something else I need to do?
The text was updated successfully, but these errors were encountered: