2

I have a simple dataset that I want to paginate using angular-js ui. It's server driven pagination since it can get quite big.

Now, I have the problem that my pagination element is not showing up.

<pagination total-items="totalItems" page="filterCriteria.pageNumber"></pagination>

is what I have, these two parameters are both correct (tested that).

At first I thought I might not have all the correct files imported, but after some checking I can't seem to find anything missing:

<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script><!-- load jquery -->
<script src="js/angular-file-upload-shim-min.js"> </script>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.0.8/angular.min.js"></script><!-- load angular -->
<script src="http://netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>
<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/angular-ui-bootstrap/0.10.0/ui-bootstrap-tpls.min.js"></script>

Any thoughts why the pagination element does not show up on my page?

4
  • 2
    have you put 'ui.bootstrap' into dependencies of your module? check the source in the browser whether pagination directive was correctly replaced by its template Commented Feb 7, 2014 at 12:39
  • No I did not, just discovered it myself. Thanks Commented Feb 7, 2014 at 12:41
  • I hope that you are aware that you don't need jQuery nor Bootstrap's JavaScript to use angular-ui/bootstrap! Commented Feb 7, 2014 at 16:43
  • Yeah, I know, I'm aware of this. Commented Feb 10, 2014 at 12:28

1 Answer 1

9

So as I commented you didn't put ui.bootstrap dependency into your module

angular.module(appName, [
   'ui.bootstrap' 
]);
Sign up to request clarification or add additional context in comments.

1 Comment

so annoyed with myself and in love with you right now!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.