Wishmitha S. Mendis
Wishmitha S. Mendis

Reputation: 127

How to add a html datalist field to a meteor aldeed:autoform?

I populated a select input field with a collection in aldeed:autoform.

Field Declaration

{{> afFormGroup name="patientID" type="select" options=patientIDs}}

Helper

patientIDs:function () {

    return Meteor.users.find({}).map(function (user) {
        return {label: user.profile.firstName, value: user._id};
    });

}

But it turned out to be the drop down too large to select an option. Therefore I need to implement a functionality similar to HTML datalist in the autoform. How to implement this in meteor aldeed:autoform?

Upvotes: 0

Views: 121

Answers (1)

tomsp
tomsp

Reputation: 1807

There is a select2 add-on for autoform, which might help get you what you want. See here.

Upvotes: 1

Related Questions