I have an element <svg>on my page and would like to give it a viewBox attribute . When I try this with jQuery, like this:
$('svg').attr('viewBox', '0 0 800 400');
It almost works, but gives the element the attribute "view b ox" (note the lower case "b"). This attribute requires the camel body to work, at least in Chrome, where I tested it. Are there any workarounds?
source
share