Re: [webcomponents] More backward-compatible templates

On Oct 30, 2012, at 9:56 PM, Yehuda Katz <yehuda.katz@jquery.com> wrote:

>  
> - Can be polyfilled with full fidelity and no risk of content that's meant to be inert accidentally running
> 
> This is a relevant concern. I could imagine several polyfill-friendly solutions that could be used without worsening the long-term ergonomics of this feature (using existing constructs for escaping).

Can you give specific examples of some other polyfill-friendly solutions?

> The nice thing about <template> is that it is a completely new construct, so future features could be added without the need to forever look over our shoulder at the (insane!) <script> tag.
>  
> - Can be translated consistently and compatibly to the XHTML syntax of HTML
> 
> Is this a real concern?

It is for some people, yes.

> 
> 
> 
> Cons:
> - <script type=template> is slightly more verbose than <template>
> - Closing of nested scripts/templates requires some escaping
> 
> 
> See above, but there are more cons.

Can you be specific about the other cons? The only ones I noticed seemed to be restatements or strengthenings of these two points, but I may have overlooked something.

Cheers,
Maciej

Received on Thursday, 1 November 2012 06:48:05 UTC