I have a ViewModel that I created with knockout which contains all the info for my product. And It looks like this:
var ProductViewModelDS = function (data)
Looking at the link you provided, have you not got your target and source the wrong way round?
Basically, it appears that the type ahead plugin wants an array of string values it can use for the auto-complete suggestions. Add a SearchText property to the ProductViewModel that loops through all the products and puts the three fields you want into the searchterm array.
var ProductViewModel = function () {
self.SearchText = ko.computed(function()
{
var searchableTerms = [];
ko.utils.arrayForEach(self.Products(), function (item)
{
searchableTerms.push(item.ProductSKUName());
searchableTerms.push(item.ProductSKUStockCode());
searchableTerms.push(item.ProductSKUManufacturePartNumber());
});
return searchableTerms;
});
};
Then update the html to something like:
<div class="well">
<input type="text" data-bind="typeahead: { target: Products, source: SearchText }" />
</div>