I have an application in AngularJS that has the following problem:
Every time I access my view using:
$ location.path ('/ my-url');
Restricted directive of type 'A' simply is not loaded normally.
<ui-carrousel {atributos}></ui-carrousel>
In the directive it takes information from the window size to resize the carousel with the images:
this.updateItemStyle = function () {
_this.itemWidth = _this.width / _this.options.slidesToShow;
_this.slideStyle = {
'width': _this.itemWidth + 'px'
};
};
Only he does this when I refresh the page ...
How do I get it rendered correctly using $ route access without having to do $ route.reload () or something like that. It has some smarter way to reapply the directive, for example, when we load an object using ng-bind="action ()".