{"action":"created","issue":{"url":"https://api.github.com/repos/ampproject/amphtml/issues/327","labels_url":"https://api.github.com/repos/ampproject/amphtml/issues/327/labels{/name}","comments_url":"https://api.github.com/repos/ampproject/amphtml/issues/327/comments","events_url":"https://api.github.com/repos/ampproject/amphtml/issues/327/events","html_url":"https://github.com/ampproject/amphtml/issues/327","id":108729542,"number":327,"title":"Discussion: <p> can break AMP with some ease","user":{"login":"dvoytenko","id":726049,"avatar_url":"https://avatars.githubusercontent.com/u/726049?v=3","gravatar_id":"","url":"https://api.github.com/users/dvoytenko","html_url":"https://github.com/dvoytenko","followers_url":"https://api.github.com/users/dvoytenko/followers","following_url":"https://api.github.com/users/dvoytenko/following{/other_user}","gists_url":"https://api.github.com/users/dvoytenko/gists{/gist_id}","starred_url":"https://api.github.com/users/dvoytenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dvoytenko/subscriptions","organizations_url":"https://api.github.com/users/dvoytenko/orgs","repos_url":"https://api.github.com/users/dvoytenko/repos","events_url":"https://api.github.com/users/dvoytenko/events{/privacy}","received_events_url":"https://api.github.com/users/dvoytenko/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ampproject/amphtml/labels/Discussion","name":"Discussion","color":"207de5"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-09-28T19:27:13Z","updated_at":"2015-12-17T22:14:09Z","closed_at":null,"body":"This is a well-known and somewhat documented issue, but we may want to think if we can do anything to make it less of a trap. Consider this:\r\n```\r\n<p>\r\n  <amp-carousel>\r\n    <div slide1></div>\r\n    <div slide2></div>\r\n  </amp-carousel>\r\n</p>\r\n```\r\n\r\nThis code fragment will be completely messed by the browser. It will actually end up being this:\r\n```\r\n<p>\r\n  <amp-carousel>\r\n  </amp-carousel>\r\n</p>\r\n<div slide1></div>\r\n<div slide2></div>\r\n```\r\n\r\nThis is, of course, because HTML spec states that `<p>` is automatically closed by `<div>` and a host of other tags. In other words, `<p>` is really bad for composition.\r\n"},"comment":{"url":"https://api.github.com/repos/ampproject/amphtml/issues/comments/165597151","html_url":"https://github.com/ampproject/amphtml/issues/327#issuecomment-165597151","issue_url":"https://api.github.com/repos/ampproject/amphtml/issues/327","id":165597151,"user":{"login":"jmadler","id":435158,"avatar_url":"https://avatars.githubusercontent.com/u/435158?v=3","gravatar_id":"","url":"https://api.github.com/users/jmadler","html_url":"https://github.com/jmadler","followers_url":"https://api.github.com/users/jmadler/followers","following_url":"https://api.github.com/users/jmadler/following{/other_user}","gists_url":"https://api.github.com/users/jmadler/gists{/gist_id}","starred_url":"https://api.github.com/users/jmadler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmadler/subscriptions","organizations_url":"https://api.github.com/users/jmadler/orgs","repos_url":"https://api.github.com/users/jmadler/repos","events_url":"https://api.github.com/users/jmadler/events{/privacy}","received_events_url":"https://api.github.com/users/jmadler/received_events","type":"User","site_admin":false},"created_at":"2015-12-17T22:14:09Z","updated_at":"2015-12-17T22:14:09Z","body":"I think we should just not allow \\<p\\> in favor of \\<div\\> due to its unexpected behavior."}}