In ionic v1 I was declaring my global variables in app.js but I am not getting any picture where to declare my global variable in ionic v2.
Particular I want to declare a puchdb variable and use it in all js.
var localDB = new PouchDB("dbname");
var remoteDB = new PouchDB("http://username:password@192.168.1.79:5984/dbname");
I was declaring it bellow the following line and using in external controllers and services js file. But here I am confused. There must be some way.
var app = angular.module('starter', ['ionic']);