Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

svg css viewbox

// I haven't yet found a way to change the viewBox property with CSS. 
// However this Javascript solution works well:

let mySVG = document.getElementById('svg');
mySVG.setAttribute("viewBox", "0 0 100 100");
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #svg #css #viewbox
ADD COMMENT
Topic
Name
8+1 =