6 Replies Latest reply on Jan 3, 2013 3:59 AM by rafael moterle

    js size

      the rhoelements have any size restriction. js?


      rhoelements hangs with my js greater than 6 mb

        • Re: js size
          Derek Warren

          What device are you testing this with?

           

          Is this a Native RhoElements application or is the js file hosted on a server?

          1 of 1 people found this helpful
            • Re: js size

              My device is a ES400


              and I have a html page that reads a js which has more than 6mb

               


              local file js

                • Re: js size
                  Benedict Kennedy

                  I would think that crash would be caused by the device running out of memory. I must say that I haven't tried importing large JavaScript files so I can't be sure.

                   

                  It could also be caused by the time taken to parse and run the JavaScript, 6MB is a lot to process. How long have you left the device for? It might wake up after a period of time. JavaScript runs on the same, single thread as the graphics do so a lot of JS processing will lock the interface.

                   

                  May I ask what sort of JavaScript it is? For example. is it script, data or a mix of both?

                   

                  A possible remedy to the symptom is to minify your JavaScript so that it takes less memory: http://crockford.com/javascript/jsmin

                  1 of 1 people found this helpful