[Solved] [V2] Searchbar and content in a Popup

I have framework7 installed and a basic site. I am debugging it using the browser platform.

From NPM:
±- [email protected]
| ±- [email protected]
| ±- [email protected]
| `-- [email protected]
±- [email protected]

I have the basics working, static popups etc.

When I use the example code for a searchbar

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);

My browser throws an error “app.searchbar.create” is not a valid function:

my-app.js:17 Uncaught TypeError: app.searchbar.create is not a function
at my-app.js:17

I assume this is an older version 1 example – is there another for v2 or can someone link me to an example somewhere else…


app.searchbar.create is actually correct and it is for v2.

I assume you may included just the core version of F7 http://framework7.io/docs/installation.html#es-module

I had an older framework7 js file getting copied in. I got it going, thanks.