Jigar Tarsariya Jigar Tarsariya - 5 months ago 16x
Swift Question

Good starting point for calling api in ionic framework

I am new in ionic framework so i don't have much idea. I want to know that how do i call api using ionic in my app? please anybody have any idea then suggest me.

Ved Ved

Integrating a API Service with AngularJS in Ionic

 angular.module('ionicApp', [])

 .controller('MainCtrl', function($scope, $http) {
      $http.get('https://cors-test.appspot.com/test').then(function(resp) {
         console.log('Success', resp);
          // For JSON responses, resp.data contains the result
       }, function(err) {
         console.error('ERR', err);
         // err.status will contain the status code