The specified value for... what?

I see this error in the console of an application with many form fields, and I have no idea what it's about:

The specified value "NaN" is not a valid number. The value must match to the following regular expression: -?(\d+|\d+.\d+|.\d+)([eE][-+]?\d+)?

Aside from the type ("must match to" -> "must match"), the error could be more useful if it named that hard-to-read regular expression ("number" in this case), and, more importantly, if it said which field (or whatever it is Webix didn't like) had that value. For example:

The specified value "Nan" for custId should be a number

Tagged:

Comments

  • Hey @dandv, seems like this is an error being thrown by the browser itself, not Webix, so we can't really change the displayed message here. As for the error itself, looks like it is somehow related to an incorrect data trying to be displayed in an input with type="number" (at least, it seems to be the most plausible explanation). So for instance you could get a response from the server that is NaN and try to set the value of a control with type="number with that data and get the error afterwards.

    I couldn't really reproduce the issue on my side, maybe you will be able to do so and provide a snippet to make sure this is the case?

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion