app.virtualList.get doesn't work on a dynamic page

Hi, I have a virtualList on my home page and it is initialised in app.js.

app.virtualList.get(".virtual-list"); in app.js work perfect when I’m on the home page, but when I’m on a dynamic template7 page and perform the same app.virtualList.get(".virtual-list"); in app.js I get nothing (undefinded) back. Where is the error?

When I log the variable app on a dynamic template7 page, I don’t get the current view correct: app.views.current is “-”.

Need an example or JSFiddle with the issue