- Code works specific to one smiley face
- Code needs to be modified if you want to reuse the smile face multiple times
- Avoid setting any width to SVG, it is being set in BG
- Avoid changing any values inside SVG
Solution: <meta http-equiv="refresh" content="seconds">
Use this meta tag where you provide value in place of seconds
. Then it will simply refresh the page in set time interval.
Answer: As the name suggests animVal (animation value) referes to current value of the attribute (in case it is changed by any animation) and baseVal refers to the base value that doesn't change even after animation is applied. Both values remains the same until you are using any Animation Elements.
Reference: SVG: when to use animVal / baseVal
Solution: I am simply using ElementYouWantToScale.setAttribute("transform", "scale(1.5)");
Work on this