1. Ease of distribution / simpler project structure. 2. Speed of compiling. SWC libraries have the Javascript compiled when the SWC is generated. When an app uses the SWC, the JS is copied from the SWC and only if it wasn’t already copied.
You can also use different compiler options when compiling the libs than the client app. Harbs > On Jun 27, 2020, at 10:34 PM, Andrew Wetmore <[email protected]> wrote: > > Naive question: what is the benefit of compiling something into a SWC? I > have built lots of apps whose components are pure ActionScript and MXML and > that (in theory) Royale can transform fine into JS. > > Andrew > > On Sat, Jun 27, 2020 at 3:57 PM Harbs <[email protected]> wrote: > >> For example projects which compile to SWC please see: >> >> https://github.com/unhurdle/cep-royale/tree/master/CEPTools >> https://github.com/unhurdle/spectrum-royale/tree/master/Spectrum >> >> One thing to be aware of: You need the full swf-compatible Royale SDK to >> produce SWCs. >> >> HTH, >> Harbs >> >>> On Jun 27, 2020, at 5:16 AM, Hugo Ferreira <[email protected]> >> wrote: >>> >>> With Apache Flex I can build my own reusable components (SWC). >>> Can I do the same approach with Apache Royale or this is not possible or >>> easy on this framework (at least I did not find any mention about that) ? >> >> > > -- > Andrew Wetmore > > http://cottage14.blogspot.com/
