0

I'm new in AngularJs. I try to make web with AngularJs and Bootstrap. when I call bootstrap modal I use this script :

    $scope.here = function here(f) {
         $('#smallModal').modal();
         $('#contentin').html(f);   
}

that code I call use ng-click=here('test') in my header html i still use Jquery library. My question is , is it posiblle to unload jquery for call modal bootstrap who called with $ prefix. I don't want to use any plugin except AngularJs

2 Answers2

1

If you want to make use of Bootstrap's modal, one option is to use Angular-UI's Bootstrap (if that isn't what you're already using), which puts Bootstrap components into Angular directives for you. Specifically, you would inject the $modal service into whatever module needs to control the modal. Here's an example of how to use the $modal service.

mbil
  • 106
  • 6
0

There are many ways of displaying model dialog out there. You can easily search with google. btw, AngularJS use jQuery - or jQuery lite in the backend.

Thai Anh Duc
  • 524
  • 6
  • 12
  • angular has no jQuery dependency. This is not really a very valid answer to the question – charlietfl Mar 23 '15 at 23:18
  • Angular does have a dependency on jqlite. A stripped down version of jQuery. If you require jQuery first it will use that instead. http://stackoverflow.com/a/15725017/124220 – Joel Mar 23 '15 at 23:26
  • well i mean the lite version of it. It is not a strong dependency – Thai Anh Duc Mar 24 '15 at 03:01