I used your code and then changed it slightly to get rid of deprecation warning (no instantiation):
.factory('LoadingService', function($ionicLoading) {
return {
show: function(content) {
$ionicLoading.show({
template: (angular.isDefined(content) ? content : 'Loading...')
});
},
hide: function() {
$ionicLoading.hide();
}
};
})