forked from chengz/schema-form-strapselect
    
        
        - 
                Notifications
    
You must be signed in to change notification settings  - Fork 45
 
Open
Description
I have a need for a field that retrieves its options via an HTTP request (to an API). The structure of the response to that GET request is, for example;
{
    _embedded: {
        people: [
            // The array of options
        ]
    }
}
I found the optionsCallback option in the documentation however since the form schema (which is dynamic and provided by an API) could in theory contain infinite different API endpoint providers of options for different fields (with differing response keys in place of "people") creating a callback to pluck the options out is less feasible.
Is there a way to do something similar to the following? Thanks
"options": {
    "multiple": "true"
    "httpGet": {
        "url" : "http://my-api.com/people",
        "dataPath": "_embedded.people"
    }
}
Metadata
Metadata
Assignees
Labels
No labels