PSA: --enable-html-imports is gone.

81 views
Skip to first unread message

Hajime Morrita

unread,
Apr 7, 2014, 7:40:36 PM4/7/14
to polym...@googlegroups.com
Hello Polymerians,

I just removed "--enable-html-imports" flag from ToT Chrome. You'll see it in next Canary. Now HTML Imports is enabled with "--enable-experimental-web-features". I believe major blockers are already hunted, but if you find new problems, please file a bug with "Cr-Blink-WebComponents" label. I'm eager to beat all of them.

Bests,
--
morrita

Jan Miksovsky

unread,
Apr 8, 2014, 6:02:11 PM4/8/14
to polym...@googlegroups.com
Hajime: This is great to see!

Now that HTML Imports are automatically enabled with all experimental platform features, this is exposing my app (in Canary) to a bug that prevents the use of UTF-8 in imported Polymer elements. That's a non-trivial bug, so I'm hoping that can be addressed soon.

John Messerly

unread,
Apr 8, 2014, 6:10:37 PM4/8/14
to Jan Miksovsky, polymer-dev
it looks like a fix happened, then the patch was abandoned?

It's also important to make sure that imports don't trigger quirks mode if no doctype is present.

It would be sad if every import HTML needed to start with:

<!doctype html>
<html>
<head>
<meta charset="utf-8">
</head>

Polymer's elements don't do that:

and it's a good thing IMHO :)




Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/02ecbb74-974d-4f98-b138-b37df4a1b4da%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Hajime Morrita

unread,
Apr 8, 2014, 7:05:15 PM4/8/14
to John Messerly, Jan Miksovsky, polymer-dev
Jan:
Well, this is something we have to decide how it should work. There are some discussion on spec side but I agree that it's time to roll it up.

John:
Quirks thing is tricky and Blink might need some polish there.
Even if there are quirks mode of imports, rendering is happening in the main ("master") document. It is not clear what quirks mode for imports means. My gut feeling is that it should follow the mode of the master document. 




John Messerly

unread,
Apr 8, 2014, 7:54:19 PM4/8/14
to Hajime Morrita, Jan Miksovsky, polymer-dev
On Tue, Apr 8, 2014 at 4:05 PM, Hajime Morrita <mor...@chromium.org> wrote:
Jan:
Well, this is something we have to decide how it should work. There are some discussion on spec side but I agree that it's time to roll it up.

John:
Quirks thing is tricky and Blink might need some polish there.
Even if there are quirks mode of imports, rendering is happening in the main ("master") document. It is not clear what quirks mode for imports means. My gut feeling is that it should follow the mode of the master document. 

makes sense :).

I doubled check the HTML parsing spec (and html5lib implementation) and there I only found one example of quirks affecting parsing:
http://www.whatwg.org/specs/web-apps/current-work/multipage/tree-construction.html#parsing-main-inbody, under `A start tag whose tag name is "table"`. But it's somewhat obscure, and only prevents an open <p> from being closed by a <table>. So perhaps not a big deal after all.

Jan Miksovsky

unread,
Apr 10, 2014, 12:06:18 PM4/10/14
to polym...@googlegroups.com, Hajime Morrita, Jan Miksovsky
Until this is fixed, I just wanted to document a workaround for UTF-8 problems: add an appropriate meta tag to the top of the imported file (e.g., imported Polymer element definition):

<meta charset="utf-8">

This works in both Canary and polyfilled browsers. It's unfortunate to have to include this in every file that contains UTF-8 (I often use Unicode characters as icon glyphs, for example), but at least it's easy enough to do. Once the question of how HTML Imports should assume UTF-8 is resolved, the meta tag can be removed.
Reply all
Reply to author
Forward
0 new messages