http://plnkr.co/edit/GRVZl35D1cuWz1kzXZfF?p=preview
In custom fancybox (aka lightbox, dialog), I display content with interpolated values.
in the service, in the "open" fancybox method, I do
open: function(html, $scope) {
var el = angular.element(html);
$compile(el)($scope);
$.fancybox.open(el);
}
The problem is that the contents in the dialog are loaded until the end of the compilation of $, so after less than a second I received an update to the contents of the dialog with the values.
Plunkr works, but I want to avoid that "el" is displayed before it is fully compiled: I want to show it only after the compilation has completed.
Is there any way to know when this value compiles, so I will only show the content on fancybox after that?