I wrote ui.router to get data from JSON file. I am not getting error messages, but code does not enter "resolve" part. So I cannot get data from JSON file.
Can anyone tell me what could possibly make this happen and the way to fix it?
Here is my code. (function(){
/*
 * Declaration of main angular module for this application.
 *
 * It is named turtleFacts and has no dependencies (hence the 
 * empty array as the second argument)
 */
angular
    .module('GrammarQuiz', ['ui.router'])
    .config(
        function($stateProvider, $urlRouterProvider) {
        console.log('HOLY SMOKES, I CAN BREATHE IN HERE')
        $urlRouterProvider.otherwise('/browse/1');
        $stateProvider
            .state('home',{
            url: "/#/testtest",
            resolve: {
                questions: function($http){
                    console.log('!!#@!#@!');
                    return $http({
                        method: 'GET',
                        url: 'api/data1.json'
                    }).error(function(data,status,headers,config){
                        console.log('thisi now working!!!!');
                    })
                }
            }
        })
     })
})();
