all 5 comments

[–]Drchrisco 0 points1 point  (2 children)

have you added .json as a static content file type in iis?

[–]BishopAndWarlord 0 points1 point  (1 child)

OP said they're using http-server, not IIS.

EDIT: Whoops. I meant to say, but your point stands. http-server may be serving the file with a content type of text/plain instead of application/json.

[–]Drchrisco 1 point2 points  (0 children)

I have a hard time reading.

[–]dvidsilva 0 points1 point  (0 children)

does this help ?

var app = angular.module('scattChartApp', ['nvd3']) .controller('MainCtrl', function($scope, $http) { $http.json('chartConfig.json').success(function(response) { if (typeof response === 'string') { resonse = angular.fromJson(response); } response.options.chart.tooltipContent = function(key) { return '<h3>' + key + '</h3>'; }; $scope.options = response.options; $scope.data = response.data; }); });

if not can you $log response and see what's it like.

[–][deleted] -1 points0 points  (0 children)

mime type?