hello,
i create compnent page with dynamic data and i put search bar funtion in :
on: {
pageInit: function (e, page) {
var app = new Framework7();
// create searchbar
var searchbar = app.searchbar.create({
el: ‘.searchbar’,
searchContainer: ‘.list’,
searchIn: ‘.item-title’,
on: {
search(sb, query, previousQuery) {
console.log(query, previousQuery);
}
}
});
},
every thing work good but when i go to same page from menu but get another data it’s work but search bar is not working i thing page is initialized before i use :
pageReinit: function (e, page) {
var app = new Framework7();
// create searchbar
var searchbar = app.searchbar.create({
el: ‘.searchbar’,
searchContainer: ‘.list’,
searchIn: ‘.item-title’,
on: {
search(sb, query, previousQuery) {
console.log(query, previousQuery);
}
}
});
}
but is not working can you help me please…