We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
parse error in forms with decimal.
In Form.fs:
type MyForm = { Value: decimal }
In View.fs
{ Label = "Data"; Html = formInput (fun f -> <@ f.Value @>) [] }
entering a negative number like "-10" lead in the form lead to "Cound not parse '-10' to Decimal"
workaround by using string, validate them by regexp, and convert the string to decimal
type MyForm = { Value: string } let decimalNumberPattern = matches @"-{0,1}\d*(\.{0,1}\d*)" let priceAdjustment: Form<PriceAdjustment> = Form ([ TextProp ((fun f -> <@ f.Value @>), [decimalNumberPattern]) ], [] )
The text was updated successfully, but these errors were encountered:
7308779
No branches or pull requests
parse error in forms with decimal.
In Form.fs:
In View.fs
entering a negative number like "-10" lead in the form lead to
"Cound not parse '-10' to Decimal"
workaround by using string, validate them by regexp, and convert the string to decimal
The text was updated successfully, but these errors were encountered: