0 Replies Latest reply on Feb 4, 2014 2:09 PM by rsriniva

    Gatein 3.6 - Bypass require.js loading and fall back to legacy JS loading?

    rsriniva

      Is there a way to bypass require.js loading completely and fall back to legacy JS loading in new Gatein releases (3.6.x)?

       

      We have a portlet app deployed on Gatein 3.3 which we are migrating to 3.6 which makes heavy use of a 3rd party JS framework and it uses Dojo loader underneath (ESRI javascript SDK). I understand there is still no full compatibility between require.js and dojo. The 3rd party JS product is minified, optimized and obfuscated

       

      We tried loading via SCRIPT tags as well as via module loading and script loading in gatein-resources.xml but we still get weird javascript errors. Even adapter does not help

       

      Is there a way to bypass require.js loading completely? Please note that third party JS cannot be modified (scripts work fine in normal tomcat and jboss inside a regular web app)

       

      Any other workaround to make this work under 3.6?

       

      I understand all the benefits of AMD and I know require.js is the new cool kid on the block - but why no option to turn it OFF and fall  back to legacy mode?