{"action":"created","issue":{"url":"https://api.github.com/repos/kangax/fabric.js/issues/1874","labels_url":"https://api.github.com/repos/kangax/fabric.js/issues/1874/labels{/name}","comments_url":"https://api.github.com/repos/kangax/fabric.js/issues/1874/comments","events_url":"https://api.github.com/repos/kangax/fabric.js/issues/1874/events","html_url":"https://github.com/kangax/fabric.js/issues/1874","id":50744389,"number":1874,"title":"SVGs without Width and Height display at '0' size","user":{"login":"justrhysism","id":1326759,"avatar_url":"https://avatars.githubusercontent.com/u/1326759?v=3","gravatar_id":"","url":"https://api.github.com/users/justrhysism","html_url":"https://github.com/justrhysism","followers_url":"https://api.github.com/users/justrhysism/followers","following_url":"https://api.github.com/users/justrhysism/following{/other_user}","gists_url":"https://api.github.com/users/justrhysism/gists{/gist_id}","starred_url":"https://api.github.com/users/justrhysism/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justrhysism/subscriptions","organizations_url":"https://api.github.com/users/justrhysism/orgs","repos_url":"https://api.github.com/users/justrhysism/repos","events_url":"https://api.github.com/users/justrhysism/events{/privacy}","received_events_url":"https://api.github.com/users/justrhysism/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2014-12-02T23:20:46Z","updated_at":"2015-04-01T15:50:10Z","closed_at":"2015-04-01T15:50:10Z","body":"To provide the most consistent behaviour between browsers, sometimes SVGs as images need to omit the `width` and `height` attributes. [See http://www.boogdesign.com/examples/svg/svg-as-image.html in Chrome and IE]\r\n\r\nHowever there is inconsistent behaviour between browsers when adding such SVGs as Fabric Images to the Canvas. In Chrome, the SVGs appear to have a `naturalWidth` of `300` and `naturalHeight` of `150`. However in IE and FF, these values are `0`, and as such, when added to the canvas, aren't visible (however can be \"found\" by group selecting over the canvas.\r\n\r\nhttp://jsbin.com/viluca/8/edit \r\n\r\nThis isn't necessarily a _bug_ in the respective browsers or Fabric, however it would be _nice_ if Fabric handled it nicely.\r\n\r\n\r\n\r\n<bountysource-plugin>\r\n---\r\nWant to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/6710793-svgs-without-width-and-height-display-at-0-size?utm_campaign=plugin&utm_content=tracker%2F23217&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F23217&utm_medium=issues&utm_source=github).\r\n</bountysource-plugin>"},"comment":{"url":"https://api.github.com/repos/kangax/fabric.js/issues/comments/88530155","html_url":"https://github.com/kangax/fabric.js/issues/1874#issuecomment-88530155","issue_url":"https://api.github.com/repos/kangax/fabric.js/issues/1874","id":88530155,"user":{"login":"asturur","id":1194048,"avatar_url":"https://avatars.githubusercontent.com/u/1194048?v=3","gravatar_id":"","url":"https://api.github.com/users/asturur","html_url":"https://github.com/asturur","followers_url":"https://api.github.com/users/asturur/followers","following_url":"https://api.github.com/users/asturur/following{/other_user}","gists_url":"https://api.github.com/users/asturur/gists{/gist_id}","starred_url":"https://api.github.com/users/asturur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asturur/subscriptions","organizations_url":"https://api.github.com/users/asturur/orgs","repos_url":"https://api.github.com/users/asturur/repos","events_url":"https://api.github.com/users/asturur/events{/privacy}","received_events_url":"https://api.github.com/users/asturur/received_events","type":"User","site_admin":false},"created_at":"2015-04-01T15:50:10Z","updated_at":"2015-04-01T15:50:10Z","body":"sort of duplicate of #2069 @justrhysism, follow that topic to see updates."}}