Suggestions in "Basic Example"

I’m looking for a way to give users suggestions or examples values for text fields (not enum). I saw that the Basic Example in the docs has “suggestion” field in the ui-schema for occupation (Basic Example - JSON Forms).
But when I play with the demo in this example, None of the occupation suggestions is shown.

How should it work and look like?


Hi @Omri,

In the past we had some renderers which were able to read in the suggestion property and then autocomplete for its entries while still allowing free text as the input. However these renderers were removed at some point but the example was not adapted.

The suggestion should be removed from them example to avoid confusion.

1 Like

I Got it, Thank you!

@sdirix is there a workaround so we can show “suggestions” to a user and allow freetext? I see some other JSONForms sites use “examples”.

Hi @dcjarvisvt,

What you need to do is to implement a custom renderer which offers this functionality. It’s not really a workaround but the foreseen extension pattern for JSON Forms.