@Fogox wrote:
Hi all,
I would like to know a simple example about views, I was reading some articules but I still continue without understand very well how works?...
I'm new in ionic
but... I have created a simple application ( blank app)
And I have added this structure...
[...]
.config(function($stateProvider,$urlRouterProvider) {
$stateProvider.state('name-resultado', {
url: '/',
views: {
'name-resultado': {
templateUrl: 'templates/resultado.html',
controller: function($scope){
console.log("entro");
}
}
}
})[...]
so, I don't understand where I need to put the view...
my index html...
<link href="lib/ionic/css/ionic.css" rel="stylesheet"> <link href="css/style.css" rel="stylesheet"> <!-- IF using Sass (run gulp sass first), then uncomment below and remove the CSS includes above <link href="css/ionic.app.css" rel="stylesheet"> --> <!-- ionic/angularjs js --> <script src="lib/ionic/js/ionic.bundle.js"></script> <!-- cordova script (this will be a 404 during development) --> <script src="cordova.js"></script> <!-- your app's js --> <script src="js/app.js"></script>
<ion-pane> <ion-header-bar class="bar-stable"> <h1 class="title">{{header}}</h1> </ion-header-bar> <ion-content >
here....
</ion-content> </ion-pane>
and the last one...
my file "resultado.html"
Hello!
but... still contine without work
can you help me?
Thanks in advance!!
Dan
Posts: 1
Participants: 1