Skip to content
Anders Malmgren edited this page Feb 19, 2014 · 2 revisions

Minimum required option to use when you use the combobox binding is dataSource. Here is a list of all options

Option Default Function
dataSource null You can use a function or array as data source
comboboxTemplate Built in template A string that either is a ID for a template or the template itself
rowTemplate Built in template A string that either is a ID for a template or the template itself.
valueMember ‘name’ The member to use to output the text for row
pageSize 10 The size of each dropdown page
paging true Enable or disable paging
pagingLinks 4 Specifies the number of paging links shown
keyPressSearchTimeout 200 ms The throttle timeout between keypresses before a request is sent
minimumSearchTextLength 1 The minimum characters required for a request to be performed
placeholder null Placeholder text for input field
dropdownItemsArray New instance By default the combobox will instance a observableArray for the drop down items. You can instead supply your own if you want to control the items like removing items etc.

You can add default options by calling ko.bindingHandlers.combobox.setDefaults

Clone this wiki locally