Guest User

app.js

a guest
Oct 5th, 2016
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Ionic Starter App
  2.  
  3. // angular.module is a global place for creating, registering and retrieving Angular modules
  4. // 'starter' is the name of this angular module example (also set in a <body> attribute in index.html)
  5. // the 2nd parameter is an array of 'requires'
  6. var app = angular.module('starter', ['ionic'])
  7.  
  8. app.run(function($ionicPlatform) {
  9.   $ionicPlatform.ready(function() {
  10.     if(window.cordova && window.cordova.plugins.Keyboard) {
  11.       // Hide the accessory bar by default (remove this to show the accessory bar above the keyboard
  12.       // for form inputs)
  13.       cordova.plugins.Keyboard.hideKeyboardAccessoryBar(true);
  14.  
  15.       // Don't remove this line unless you know what you are doing. It stops the viewport
  16.       // from snapping when text inputs are focused. Ionic handles this internally for
  17.       // a much nicer keyboard experience.
  18.       cordova.plugins.Keyboard.disableScroll(true);
  19.     }
  20.     if(window.StatusBar) {
  21.       StatusBar.styleDefault();
  22.     }
  23.   });
  24. }).config(function($stateProvider, $urlRouterProvider) {
  25.  
  26.   $stateProvider
  27.     .state('login', {
  28.       url: "/login",
  29.       templateUrl: "templates/login.html"
  30.     })
  31.  
  32.    $urlRouterProvider.otherwise("/login");
  33. });
Add Comment
Please, Sign In to add comment