Frage

Well, we have a page running RequireJS, which loads the dependencies, creates the approuter and well, all backbone load.

On html page, we load :

<script>
    require.config({
     baseUrl: "/source/js"
    });
    require(["/source/js/main.js"], function() {
        alert('Done') ;
    }) ;
</ script>

And this, in principle does not fail (Say 'Done'), but it does not run any more. It not executes the code (In main.js):

require(
   ['routers/approuter',
     'shared'
   ],
function(AppRouter, SharedObject){
    var app_router = new AppRouter;
    etc.....

This happens only with AdBlocks, not with AdBlocks Plus. We don't have ads in the web, only require.js loading Backbone, making calls to the api and returning small pieces of json :(

I not know if could give useful information for assistance, does not load the whole site .... we are in trouble :(


Typical, solved:

Simply by having a js file called 'promotionaddform.js' adblocks blocking the entire page. .... Beware of filenames!...

Sorry for the post :(

War es hilfreich?

Lösung

Loading scripts with certain filenames causes AdBlocks to stop execution of JavaScript on that page.

One such example is promotionaladdform.js.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top