Open dreyn74 opened 6 years ago
I managed to get this template working by adding the "window" identifiers to these lines in main.js, but now there's this error: GET http://localhost:8080/cordova.js 404 (Not Found)
function handleBackButton () {
// NOTE: The back button will behave differently depending on circumstance
// If the side panel is open, close it
if (document.querySelector('.panel-left.active')) {
// This will do nothing when the split-view is open
return window.f7.closePanel();
}
// Close modals
// @TODO How to handle modals we shouldn't close like a login-screen?
if (document.querySelector('.modal-in')) {
return f7.closeModal();
}
// If we have a back button, we want it to go back
if (f7.mainView.history.length > 1) {
return f7.mainView.router.back();
}
// Default to closing the app
return window.navigator.app.exitApp();
}
to
``` diff
function handleBackButton () {
// NOTE: The back button will behave differently depending on circumstance
// If the side panel is open, close it
if (document.querySelector('.panel-left.active')) {
// This will do nothing when the split-view is open
return window.f7.closePanel();
}
// Close modals
// @TODO How to handle modals we shouldn't close like a login-screen?
if (document.querySelector('.modal-in')) {
return +window.f7.closeModal();
}
// If we have a back button, we want it to go back
if (+window.f7.mainView.history.length > 1) {
return window.f7.mainView.router.back();
}
// Default to closing the app
return window.navigator.app.exitApp();
}
yes, Routing does not seem to work. I add new route path but it's not working
import Tabs from './pages/Tabs.vue';
import About from './pages/About.vue';
import NotFoundPage from './pages/not-found.vue';
export default [
{
path: '/',
component: Tabs
},
{
path: '/about/',
component: About
},
{
path: '(.*)',
component: NotFoundPage
}
];
Page error: Cannot GET /about/
Out of the box, the routing does not seem to work.