Skip to content Skip to sidebar Skip to footer

Angularjs Pagination And Cannot Read Property 'slice' Of Undefined

Iv'e got an problem. Please help me what is wrong. There is my code : (function () { var app = angular.module('store', ['ui.bootstrap']); app.controller('StoreController'

Solution 1:

You have to check that $scope.products is defined it seems like it's undefined before the server returns its data.

You can set a check in the filter for data to be defined or initalize products in the controller to be an empty array.

Post a Comment for "Angularjs Pagination And Cannot Read Property 'slice' Of Undefined"