(Angular + Jade + UI Bootstrap) There is no style attached to the drop-down menu

I am trying to implement a dropdown menu on angular. So far I have printed a list of elements, but it looks like this:

enter image description here

Simply put, he has no style applied to him. This is what my code looks like.

index.jade

!!!
html
    head
    script(src='https://ajax.googleapis.com/ajax/libs/angularjs/1.0.6/angular.min.js')
    script(src='js/lib/uibootstrap/ui-bootstrap-tpls-0.6.0.min.js')
    ...(skip)

body(ng-app="appName")
    div(ng-controller="controllerName")
        div(class="parent")
            span(class="dropdown")
                span(class="dropdown-toggle") EBOOKS
                ul(class='dropdown-menu')
                    li(ng-repeat='item in ebook')
                        a(href="{{item.url}}", target="blank") {{item.title}}

page.js

angular.module('page', ['ui.bootstrap']);
function controllerName($scope) {
    $scope.ebook = [{
        title: 'Link to Google',
        url: 'http://www.google.com/'
    },
    {   title: 'Link to Bing',
        url: 'http://www.bing.com/'
    },
    {
        title: 'A long title testing is being done here lalalala',
        url: 'http://duckduckgo.com'
    }];
}                

I spent so much time on this, but it seems I could not get through. Please, help.

+3
source share
1 answer

Your jade does not include the ui-bootstrap CSS file. In this plunker example on the ui-bootstrap page, you will see that they use this CSS from the CDN:

<link href = "//netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css" rel = "stylesheet">

, , , -

link(href='//netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css', rel='stylesheet')

+1

All Articles