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
i see that in the credit-card-form example here that an error is stored in the model and an errMsg message is handled in the Update function. But i cannot make the error visible in the UI, nothing appears if i input a wrong character, neither if i print the error explicitly in the View function (if the error is not nil). It seems that the errMsg is never activated.
I can't find any documentation or example about this, is there something wrong in the example?
Thanks in advance!
The text was updated successfully, but these errors were encountered:
The validation functions are called by the text models whenever one receives the Update(teaMsg) call, all you have to do is pass it a message and the rest is taken care of. As for the errMsg , that's going to have whatever errors are passed into your program model itself, while the text inputs do error handling in their own Update() methods.
The errors are stored in the individual textinputs, m.inputs[n].Err , and they're set to nil if there's no error.
This is an issue that's being discussed upstream in Bubbles. It would make more sense to continue the discussions and apply improvements over there. Thank you for bringing this to our attention! We haven't forgotten about this issue
Hello,
i see that in the
credit-card-form
example here that anerror
is stored in the model and anerrMsg
message is handled in theUpdate
function. But i cannot make the error visible in the UI, nothing appears if i input a wrong character, neither if i print the error explicitly in theView
function (if the error is notnil
). It seems that theerrMsg
is never activated.I can't find any documentation or example about this, is there something wrong in the example?
Thanks in advance!
The text was updated successfully, but these errors were encountered: