Re: [FlexJS][VS Code] dual issues

2017-07-07 Thread Alex Harui
>Thanks, >Piotr > > > >- >Apache Flex PMC >piotrzarzyck...@gmail.com >-- >View this message in context: >https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-fle >x-development.247.n4.nabble.com%2FFlexJS-VS-Code-dual-issues-tp6

Re: [FlexJS][VS Code] dual issues

2017-07-07 Thread Harbs
Sounds great! Looking forward! Harbs > On Jul 7, 2017, at 2:12 AM, Josh Tynjala wrote: > > Okay, I figured out how to make VSCode switch to JS APIs instead of SWF > APIs for completion and things. In the next version of the extension, when > the targets compiler option

Re: [FlexJS][VS Code] dual issues

2017-07-07 Thread piotrz
Alex, Do you mean by teaching compiler that if I use -target=JSFlex - I will not see flash api hints in intellisence ? Thanks, Piotr - Apache Flex PMC piotrzarzyck...@gmail.com -- View this message in context: http://apache-flex-development.247.n4.nabble.com/FlexJS-VS-Code-dual

Re: [FlexJS][VS Code] dual issues

2017-07-06 Thread Josh Tynjala
The AS/MXML code intelligence in VSCode instantiates certain classes from the compiler to get the data it needs. Previously, I was instantiating a FlexProject no matter which targets were specified. Now, I instantiate a FlexJSProject when I'm sure that JS should have a higher priority than SWF

Re: [FlexJS][VS Code] dual issues

2017-07-06 Thread Alex Harui
I agree, it will be great to get JS API code-intelligence. Just out of curiosity, what did you have to change? One work item for the future is to merge the "JS" SWC into the "SWF" SWC so there is only one SWC per library instead of the current pair like Core.SWC and CoreJS.swc. I'm trying to

Re: [FlexJS][VS Code] dual issues

2017-07-06 Thread Josh Tynjala
Okay, I figured out how to make VSCode switch to JS APIs instead of SWF APIs for completion and things. In the next version of the extension, when the targets compiler option is specified in asconfig.json, and the first value isn't "SWF", the extension will offer JS APIs. That includes giving you

Re: [FlexJS][VS Code] dual issues

2017-07-06 Thread Josh Tynjala
> The js-output-type, library-path and external-library-path options are probably not needed I would get rid of -js-output-type. I assume that -targets takes precedence, but just to be safe, you shouldn't use both. -js-output-type is necessary for 0.7.0, but switch entirely to -targets with

[FlexJS][VS Code] dual issues

2017-07-06 Thread Harbs
Since updating to “dual”has been reporting lots of errors. When I build, both the debug and release builds build correctly, but the PROBLEMS window and the live code hinting report lots of (non) issues. I’m not sure what the source of the errors are, but here are the details: I’ve tried a few

Re: dual issues

2017-06-05 Thread Harbs
In compilerOptions. Here’s my tasks.json file: { // See https://go.microsoft.com/fwlink/?LinkId=733558 // for the documentation about the tasks.json format "version": "0.1.0", "command": "asconfigc", "isShellCommand": true, "args": [

Re: dual issues

2017-06-05 Thread Josh Tynjala
Are you setting debug in an argument passed to asconfigc, like this? asconfigc --debug=false Or is it specified in asconfig.json in the compilerOptions section? Both will work, but the asconfigc command line option will always override whatever is in asconfig.json. In VSCode, the generated

Re: dual issues

2017-06-04 Thread Alex Harui
For me, the Ant build calls the "compile" target in examples/build_example.xml and sets the config_arg to use frameworks/js-config.xml which has targets set to just JS. A better example might be examples/flexjs/MDLExample. For Ant, it has a src/main/config/compile-app-config.xml which specifies:

Re: dual issues

2017-06-04 Thread Harbs
That is using -js-output-type=FLEXJS My understanding is that we are supposed to use -targets=JSFlex now. Is that not right? > On Jun 4, 2017, at 5:43 PM, Alex Harui wrote: > > The examples/native/ButtonExample does not produce a SWF for me, so maybe > compare that

Re: dual issues

2017-06-04 Thread Alex Harui
The examples/native/ButtonExample does not produce a SWF for me, so maybe compare that setup against yours. HTH, -Alex On 6/4/17, 12:56 AM, "Harbs" wrote: >Good news: Prior to the switch to dual, I was not getting a minified >release build working. That’s now working.

Re: dual issues

2017-06-04 Thread Harbs
I’m seeing similar times using both ant and asconfig for debug. (Both are good.) asconfig is not compiling a release build at all — even if I specify debug=false. I have not tried with Maven. > On Jun 4, 2017, at 12:06 PM, Justin Mclean wrote: > > Hi, > >> Justin

Re: dual issues

2017-06-04 Thread Justin Mclean
Hi, > Justin you are compiling by Maven ? Yep and Debug builds are noticeably slower for me. Justin

Re: dual issues

2017-06-04 Thread Harbs
To be clear: Debug builds are as fast if not faster than they used to be. Release build are much slower. I’m getting a debug build (with remove circulars) of my (complex) app taking about 10 seconds. The release build takes about 3 minutes. > On Jun 4, 2017, at 11:57 AM, Justin Mclean

Re: dual issues

2017-06-04 Thread piotrz
As I remember Harbs is compiling it by ANT ? Am I right ? Justin you are compiling by Maven ? Piotr - Apache Flex PMC piotrzarzyck...@gmail.com -- View this message in context: http://apache-flex-development.247.n4.nabble.com/dual-issues-tp61955p62070.html Sent from the Apache Flex

Re: dual issues

2017-06-04 Thread Justin Mclean
Hi, > Bad news: It takes much longer than it used to, and I’m getting a swf file > even though I’m only using -targets=JSFlex Compiles are also taking a lot longer for me and I’m also only using the JSFlex target. Thanks, Justin

Re: dual issues

2017-06-04 Thread piotrz
Ahh..That's not good. Another thing for resolve in release definitly. Piotr - Apache Flex PMC piotrzarzyck...@gmail.com -- View this message in context: http://apache-flex-development.247.n4.nabble.com/dual-issues-tp61955p62066.html Sent from the Apache Flex Development mailing list

Re: dual issues

2017-06-04 Thread Harbs
Good news: Prior to the switch to dual, I was not getting a minified release build working. That’s now working. Bad news: It takes much longer than it used to, and I’m getting a swf file even though I’m only using -targets=JSFlex Harbs

Re: dual issues

2017-06-04 Thread Harbs
Objects like Promise, Map, Set etc. are available by default in pretty much all modern browsers. Things like await, arrow functions, let, etc. are being added by browsers all the time. I’m not sure exactly which ones have what right now, but they are pretty far along already, so that article

Re: dual issues

2017-06-04 Thread Alex Harui
I thought es6 wasn't always on by default? https://thenextweb.com/dd/2016/03/09/6-reasons-need-learn-javascript-es6-no w-not-later/#.tnw_5KKUOOPX I haven't been paying attention so maybe all browsers are fully compliant now? -Alex On 6/4/17, 12:01 AM, "Harbs" wrote:

Re: dual issues

2017-06-04 Thread Harbs
Not sure what you mean here. > On Jun 4, 2017, at 8:52 AM, Alex Harui wrote: > > Does FlexJS emit the right code to enable es6 APIs?

Re: dual issues

2017-06-03 Thread Alex Harui
On 6/3/17, 2:02 PM, "Harbs" wrote: >I just ran into another issue. > >I’m not sure why dual would have changed this, but I’m now getting an >(erroneous) error when trying to use Promises: > >Incorrect number of arguments. Expected no more than 0 > >

Re: dual issues

2017-06-03 Thread Harbs
I just ran into another issue. I’m not sure why dual would have changed this, but I’m now getting an (erroneous) error when trying to use Promises: Incorrect number of arguments. Expected no more than 0 return new Promise(function(resolve:*,reject:*):void{

Re: dual issues

2017-06-01 Thread Josh Tynjala
When they're defined in the *-config.xml files, they'll be picked up automatically without any special code in VSCode. However, now that you mention it, I need to allow app developers to customize these in asconfig.json too. - Josh On Jun 1, 2017 12:04 AM, "Alex Harui"

Re: dual issues

2017-06-01 Thread piotrz
Hi Harbs, Great news! This approach us to release! Piotr - Apache Flex PMC piotrzarzyck...@gmail.com -- View this message in context: http://apache-flex-development.247.n4.nabble.com/dual-issues-tp61955p61988.html Sent from the Apache Flex Development mailing list archive

Re: dual issues

2017-06-01 Thread Harbs
My bad. I accidentally overwrote my copy of BasicJS.swc. After fixing some issues, I got my app to run using the latest dual changes. All in all, switching to dual went a lot better than I expected. Great work, Alex! I think the switch to the dual approach was the right one. There’s still

Re: dual issues

2017-06-01 Thread Alex Harui
Josh, there are new compiler options like js-external-library-path, js-library-path, swf-library-path, swf-external-library-path. Does your VSCode integration handle these? -Alex On 5/31/17, 8:42 PM, "Josh Tynjala" wrote: >As I understand it, the compiler should just

Re: dual issues

2017-05-31 Thread Alex Harui
If targets only has JSFlex, there shouldn't be any SWF compile at all. The console should spit out what it thinks it needs to do. Keep in mind that there are now SWCs for SWFs and SWCs for JS. Prior to dual, there was a main SWC with SWF APIs that the compiler saw, and JS that it substituted in

Re: dual issues

2017-05-31 Thread Josh Tynjala
As I understand it, the compiler should just take care of differences between JS and SWF, as long as your targets option is correct. VSCode shouldn't need to do anything​ special except to pass in the correct options. There's nothing related to dual changes on my to-do list at this time, but

Re: dual issues

2017-05-31 Thread Harbs
Another weird issue: > /Users/harbs/Documents/git/PrintUI/printui-flexjs/PortedPrintUI/src/com/printui/dummy/view/Image.as(12): > col: 15 interface method imageElement in interface IImage not implemented by > class Image > > public class Image extends BinaryImage >^ >

Re: dual issues

2017-05-31 Thread Harbs
Josh, VS Code is now reporting lots of errors in the Problems window. I’m guessing it does not know how to differentiate between JS and SWF builds using dual? Is that something on your to-do list? Thanks, Harbs > On Jun 1, 2017, at 5:10 AM, Harbs wrote: > > Bingo.

Re: dual issues

2017-05-31 Thread Harbs
Bingo. Thanks! SWF output still gets all kinds of errors, but the JS output is pretty error free. I still have some fixing up to do before I can see how well it actually works, but at least the compiler is not complaining now. > On Jun 1, 2017, at 4:45 AM, Josh Tynjala

Re: dual issues

2017-05-31 Thread Harbs
The examples I see seem to use COMPILE blocks. I’m not sure how this translates to the app level. Is there a way to define a single method which overrides a SWF one and implements a new JS one (without using COMPILE blocks)? That seems to me like a pretty common use case for migrated apps. >

Re: dual issues

2017-05-31 Thread Justin Mclean
Hi, > I’m using asconfig in VSCode to compile with these settings: > "config": "flex", > "compilerOptions": { > "debug": false, > "js-output-type": "flexjs", > "source-map": false, > "library-path": [ > "lib" > ], I’ve not used VSCode but perhaps try

Re: dual issues

2017-05-31 Thread Josh Tynjala
Try replacing the js-output-type compiler option with: "targets": ["JSFlex"] - Josh On May 31, 2017 6:26 PM, "Harbs" wrote: > I’m using asconfig in VSCode to compile with these settings: > "config": "flex", > "compilerOptions": { > "debug": false, >

Re: dual issues

2017-05-31 Thread Harbs
In case I wasn’t clear, I’m not outputting SWF — only JS output. > On Jun 1, 2017, at 4:26 AM, Harbs wrote: > > I’m using asconfig in VSCode to compile with these settings: > "config": "flex", > "compilerOptions": { > "debug": false, >

Re: dual issues

2017-05-31 Thread Harbs
I’m using asconfig in VSCode to compile with these settings: "config": "flex", "compilerOptions": { "debug": false, "js-output-type": "flexjs", "source-map": false, "library-path": [ "lib" ], > On Jun 1, 2017, at 1:04 AM, Justin Mclean

Re: dual issues

2017-05-31 Thread Alex Harui
On 5/31/17, 2:38 PM, "Harbs" wrote: >I just switched to dual and I’m getting lots of errors. These errors seem >to be exactly what I was afraid of, and I’m not sure how to resolve >without being restricted by naming of properties and methods. > >1. I’m using a mask

dual issues

2017-05-31 Thread Harbs
I just switched to dual and I’m getting lots of errors. These errors seem to be exactly what I was afraid of, and I’m not sure how to resolve without being restricted by naming of properties and methods. 1. I’m using a mask setter and getter for images it’s now giving override errors. 2.