I subclassed the goog classes. That seems to help in debug mode, but for some 
reason I’m not clear on, the goog classes disappear in release mode.

You can see what I did on the sanitize branch...

> On Dec 26, 2021, at 9:35 AM, Harbs <harbs.li...@gmail.com> wrote:
> 
> I’ll try to create placeholder classes to subclass them.
> 
>> Might be simpler to just special case these two.
> 
> How would we go about that?
> 
>> On Dec 25, 2021, at 6:08 PM, Alex Harui <aha...@adobe.com.INVALID> wrote:
>> 
>> Hmm.  That may not work since you can't extend a static function.  Might be 
>> simpler to just special case these two.
>> 
>> -Alex
>> 
>> On 12/25/21, 12:08 AM, "Alex Harui" <aha...@adobe.com.INVALID> wrote:
>> 
>>   I took a look.  It does require an "extends" relationship to force the 
>> goog.require for something in GCL.swc.  I don't think we want to change 
>> that, so try a workaround.
>> 
>>   On 12/20/21, 9:02 AM, "Alex Harui" <aha...@adobe.com.INVALID> wrote:
>> 
>>       I will try to look at it this coming weekend.  One thing to try for 
>> now is to create a class that extends goog.html.SafeHtml and redirect 
>> sanitization through the subclass.  Maybe the only way to get the dependency 
>> is to have an 'extends' relationship on the dependency, since that's what 
>> EventDispatcher does.
>> 
>>       -Alex
>> 
>>       On 12/20/21, 7:16 AM, "Harbs" <harbs.li...@gmail.com> wrote:
>> 
>> 
>> 
>>> On Dec 20, 2021, at 10:20 AM, Alex Harui <aha...@adobe.com.INVALID> wrote:
>>> 
>>> I might have time this weekend to spend more time getting it to work, but 
>>> the idea is that you add to GCL.swc the .as version of whatever JS file you 
>>> need from Google Closure Library
>> 
>>           Check.
>> 
>>> , make sure the subset code in downloads.xml doesn't delete it,
>> 
>>           Check.
>> 
>>> and then if the transpiled output of, say, Label references 
>>> goog.html.SafeHtml, it should show up in the addDependency line for Label.
>> 
>> 
>>           Here’s where I’m stuck.
>> 
>>           That’s what I was expecting, but it doesn’t. I don’t know if it’s 
>> because it’s a utility function rather than a class or some other reason, 
>> but goog.html.SafeHtml and friends do not appear as dependencies.
>> 
>> 
>> 
> 

Reply via email to