2 Replies Latest reply on Aug 17, 2010 7:39 AM by ttehify

    Flex optimization

    ttehify

      Hey there,

       

      I was wondering if there are any techniques to reduce the filesize of my Flex application? With dynamic linking, it's 41k. With static linking, it's about 300k. What's all that extra heavyweight that brings it up to 300k? And by my understanding, with dynamic linking, if the user doesn't have the required libs, they will auto-download themselves right? I'm curious about whether or not I can make my app be 41k flat and bundled with everything it needs?

       

      Thanks

        • 1. Re: Flex optimization
          Flex harUI Adobe Employee

          You can run a link-report to see what is in the other 259K.  It will be

          mostly infrastructure.  Flex is a toolbox of feature-rich components and

          infrastructure.  It is the same reason that a Swiss Army knife doesn't lie

          flat.

           

          For example, the List control doesn't just handle a list of items, it also

          has code for drag-drop and tooltips and custom cursors.

           

          If you use dynamic linking you are betting that everyone already has the

          Swiss Army knife and that you only need ship the instructions on how to use

          it.  If they don't have the framework already, it will auto-download it.  I

          believe it is a pretty safe bet that folks already have the Flex framework

          these days.

           

          The only way to get to 41k all-inclusive is to write most of what you are

          using from the framework yourself so you only have code for the features you

          are using.  That will probably take much longer than just setting properties

          on the framework components.

          1 person found this helpful
          • 2. Re: Flex optimization
            ttehify Level 1

            Thanks...

             

            Where does the content auto-download from? What do you mean by writing what I need from the framework itself? Do you mean writing it in pure ActionScript?