Re: RE: Example of access external JS using Apache Royale

2019-05-02 Thread Carlos Rovira
Hi Josh, I think this piece of knowledge you just exposed here is key for the success of Royale. I'll try to use this in TDJ to experiment with it and will use in the blog example I plan to do. thanks! El jue., 2 may. 2019 a las 16:36, Josh Tynjala () escribió: > > Users can't do this, they

RE: RE: Example of access external JS using Apache Royale

2019-05-02 Thread Yishay Weiss
Helpful, thanks. From: Josh Tynjala Sent: Thursday, May 2, 2019 5:36:35 PM To: dev@royale.apache.org Subject: Re: RE: Example of access external JS using Apache Royale > Users can't do this, they required that Royale framework devs add typed

Re: RE: Example of access external JS using Apache Royale

2019-05-02 Thread Josh Tynjala
> Users can't do this, they required that Royale framework devs add typedefs to > the typedefs repo and wait to next SDK release. What does not seems very > useful. Users can create their own typedefs from scratch. I just created a quick example for hljs, that exposes the highlightBlock()

Re: RE: Example of access external JS using Apache Royale

2019-05-02 Thread Carlos Rovira
Hi, to sumarize (let me know if I'm wrong), the current ways to integrate an existing library are 3: 1.- access vía brackets notation: This is the most easy and direct, an example is TourDeJewel in class utils.HighlightCode var hljs:Object = window["hljs"]; hljs["highlightBlock"](block); but

Re: RE: Example of access external JS using Apache Royale

2019-05-01 Thread Josh Tynjala
You still need write the Royale typedefs manually. However, referring to the TypeScript definitions while you do it makes things easier. TypeScript definitions are limited to the API surface only, without implementations of everything, so you don't need to sift through the entire JS library to