Combining Josh’s idea and this one sounds really interesting. > It is probably technically possible. But would it attract TS folks?
I don’t know, but there’s lots of advantages to Flex that might attract folks if they could use a language they’re comfortable with. I’m not sure how well TypeScript transpiled code gets handled by the Google compiler where it would have to go for minification. > 1) have FalconJX output TS as well as JS I’m not sure I understand the value of this. > 2) extend AS with some of the popular TS features That would be nice. ES6/7/8 features as well. > 3) make sure it is really easy to use TS libraries in FlexJS. A big +1 on this. > On Aug 7, 2017, at 7:39 PM, Alex Harui <aha...@adobe.com.INVALID> wrote: > > Sure, trying to replicate the TS compiler in our code base would be a lot > of work especially if we wanted to also get SWF output. > > But I think for JS-only output there is a possible shortcut where we > replace Google Closure Compiler with the TS compiler and essentially pass > through the TS code. > > Of course, I could be wrong. > > -Alex > > On 8/7/17, 9:16 AM, "Josh Tynjala" <joshtynj...@gmail.com> wrote: > >> I've considered the idea of extending the TypeScript compiler to >> understand >> MXML, and <fx:Script> elements would contain TypeScript instead of >> ActionScript. Creating a new compiler for TypeScript would be a massive >> effort (even considering the similarities between ActionScript and >> TypeScript), so it would be better to piggyback on Microsoft's work, in my >> opinion. Especially since it would be a never-ending game of catch up as >> TypeScript continues to evolve. >> >> - Josh >> >> On Mon, Aug 7, 2017 at 8:11 AM, Harbs <harbs.li...@gmail.com> wrote: >> >>> I was thinking about how we could increase adoption of FlexJS and I had >>> a >>> thought: >>> >>> How crazy would it be to make Falcon understand TypeScript? >>> >>> TypeScript is currently very popular for many of the reasons that we >>> like >>> ActionScript. The difference is that ActionScript is not the current >>> fad. >>> There are also many js libraries written in TypeScript. >>> >>> If FalconJX would be able to compile .as files alongside .ts files, >>> TypeScript code could become first-class citizens in the FlexJS >>> ecosystem. >>> That would accomplish two things: >>> >>> 1. TypeScript code could be used as-is in a project. >>> 2. It would make FlexJS an option for many TypeScript developers and >>> give >>> FlexJS a shot at vastly increased adoption. >>> >>> Thoughts? >>> Harbs >