In Angular2 With Bootstrap - Tooltip, Tooltip Need setup by executing javascript, How to do it? -


angular2 (2.0.0-rc.4) use bootstrap's tooltip, tooltip need execute follow javascript when ready:

$(function () {   $('[data-toggle="tooltip"]').tooltip() }) 

in angular2,how execute it?

<div data-toggle="tooltip" #tooltip></div> 
class mycomponent {   @viewchild('tooltip') tooltip:elementref;    ngafterviewinit() {     this.tooltip.nativeelement.tooltip();   } }     

Comments

Popular posts from this blog

django - (fields.E300) Field defines a relation with model 'AbstractEmailUser' which is either not installed, or is abstract -

matlab - error with cyclic autocorrelation function -

php - Using grpc in Laravel, "Class 'Grpc\ChannelCredentials' not found." -