I\'m setting a SVG as background-image for a pseudo element:
background-image
content: \'\'; position: absolute; right: 0; bottom: 0; left: 0; width: 100%; he
You can use the encodeURIComponent(uri) function of JS.
encodeURIComponent(uri)
This function encodes special characters and can encodes also the following characters: , / ? : @ & = + $ #
, / ? : @ & = + $ #
Reference: https://www.w3schools.com/jsref/jsref_encodeuricomponent.asp