-2

Is there any way to switch page, using ons-navigator without ons-template tag? For example, i have project like this:

--app.js
--index.html
--page1.html

When i describe page1.html into index.html, using ons-template (like this http://codepen.io/onsen/pen/yrhtv) everything is going OK. But if i'am trying to set path into

myNavigator.pushPage('page1.html', { animation : 'slide' } )

without using ons-template my app doesn't work.

user3258741
  • 93
  • 1
  • 7
  • Are you serving the app with a web server or are you just opening the file with your browser? You need to use a web server since Onsen will make a request to fetch `page1.html`. – Andreas Argelius Dec 22 '14 at 02:03

1 Answers1

0

You can use <ons-template> without <ons-navigator> but not the other way around. Navigator object is something like Angular routing system and it needs templates in order to send data between pages.

Novarac23
  • 155
  • 1
  • 1
  • 9