Running Experiments on an AnguilarJs Page

Understand Angular JS

You can now run experiments on your AnguilarJs pages using some custom integration. Mainly, you have to "tell" Convert Experiments when is the content to be tested loaded and rendered on page. Like that, Convert scripts can apply the variation changes.

The script you need to use to "tell" Convert Experiments when is the content to be tested loaded and rendered on page is as follows:


    _conv_q = _conv_q || [];  
    _conv_q.push(["run","true"]);

In your AguilarJs page you  can add it inside your AnguilaJs controller, something similar to the below:


     $scope.$on('$viewContentLoaded', function() {
         _conv_q = _conv_q || [];  
         _conv_q.push(["run","true"]);
     });

Note: if you change other elements than the ones for which you "announced" the loading complete (through the same experiment or other experiment on the same page(s) ), you need to be careful since those changes will be applied each time you call _conv_q.push(["run","true"]); and therefore it could result in different rendering;

Have more questions? Submit a request

Comments