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'm guessing we don't want to go with the "expected behavior", but rather just document this? i.e., error.property is equal to ajv's dataPath, which is just Javascript property accessor notation to get the value.
epicfaace
added a commit
to epicfaace/react-jsonschema-form
that referenced
this issue
Jan 20, 2019
* #838 return schemaPath in transformErrors
* #818 document structure of errors object in transformErrors
* fix: take into account ajv bug
* doc: re-add doc for transformErrors
Prerequisites
Description
Error objects in the errors collection passed into the transformErrors callback are inconsistent
Field paths have two different syntaxes.
Property keys can delimited by
.
and also encapsulated by[]
when special characters or white space is presentThis may be intentional but it is a breaking change introduced in v1.0.0.
It would be nice to have this noted in the release notes.
Steps to Reproduce
Expected behavior
-> "['firstName']"
-> "['first-name']"
Actual behavior
-> ".firstName"
-> "['first-name']"
Version
1.0.0
The text was updated successfully, but these errors were encountered: