I have the following AJAX request
$.ajax({
type: "GET",
url: "Control/Search/genre.php",
async: true,
success: function(text) {
content = JSON.parse(text);
console.log(content);
$('.ui.search')
.search({
source: content,
searchFields : [
'genre'
],
})
;
}
});
According to the documentation here http://semantic-ui.com/modules/search.html#/usage source: content
should expect content to be an array containing arrays or an array containing objects.
My AJAX repsonse is as follows:
[Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object]
The issue I'm having is that my search field
<div class="ui search">
<input name="genre" class="prompt" type="text" placeholder="Genre">
<div class="results"></div>
</div>
Isn't being populated by any pre-determined results as the docs promise.
Perhaps there's something wrong with my content
?