Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[0.8] Self-closing p tag breaks template #1455

Closed
ngduc opened this issue Apr 26, 2015 · 4 comments
Closed

[0.8] Self-closing p tag breaks template #1455

ngduc opened this issue Apr 26, 2015 · 4 comments

Comments

@ngduc
Copy link

ngduc commented Apr 26, 2015

Hi,
I got a strange issue. When I use a self-closing p tag </p> , it breaks my element. (doesn't let me use another element). Please check the example below:
http://howjs.com/Odsv/2#html

After I changed it to <p></p> then it works.
http://howjs.com/tbLU/2#html

@sjmiles
Copy link
Contributor

sjmiles commented Apr 28, 2015

The only void tags supported by HTML are area, base, br, col, command, embed, hr, img, input, keygen, link, meta, param, source, track, wbr.

See some discussion here: http://stackoverflow.com/questions/3558119/are-self-closing-tags-valid-in-html5

@ngduc
Copy link
Author

ngduc commented Apr 28, 2015

Thanks @sjmiles for the info.

Just curious why an invalid tag can break Polymer like that? how about some arbitrary tags ?
Can this be fixed ? Thanks.

@dhubler
Copy link

dhubler commented Apr 28, 2015

especially not arbitrary tags. A lot of people learn this the hard way and
speaking for myself, once i know, I rarely make the mistake again.

On Tue, Apr 28, 2015 at 1:12 PM Duc Ng [email protected] wrote:

Thanks @sjmiles https://github.com/sjmiles for the info.

Just curious why an invalid tag can break Polymer like that? how about
some arbitrary tags ?
Can this be fixed ? Thanks.


Reply to this email directly or view it on GitHub
#1455 (comment).

@kevinpschaaf
Copy link
Member

This can't be fixed, using an invalid closing tag breaks the HTML parser in the browser.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants