-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Description
Prerequisites
- I have read the documentation
What theme are you using?
core
Is your feature request related to a problem? Please describe.
When no widget for a given specification can be found, the error message does not mention where the error occurs, although the context is available to the code.
Example playground link: Array with "ui:widget": "radio"
Describe the solution you'd like
The error should mention where in the schema the problem occurs.
The call stack for specific error looks like this:
getWidget(): getWidget.js: 114
renderCustomWidget(): ArrayField.js: 444
render(): ArrayField.js: 369
In render() in ArrayField.js, all the necessary information for a more meaningful Error message is available: schema and idSchema give the context which developers can use to pinpoint the problem (an invalid widget specification in this case).
Describe alternatives you've considered
Setting a breakpoint at getWidget.js:114 can also be used, but only if the problem is reproducible for developers. Users reporting the error typically don't have this possibility.