Fit SVG into its parent

Open example in a new page and resize the result window to check how the SVG is fitted to his parent.

If what you want is to scale SVG backgrounds, you can check it easily on MDN web docs.