Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS Animating SVG with CSS Keyframe and Line Drawing Animations The Animation Challenge Solution

Andrew Lim
Andrew Lim
8,004 Points

Why does this not work if you don't set the transform: scale(1); in the grow keyframes?

I almost got this right, from Guil's solution, I did not include the transform: scale(1); on the @keyframes grow. When these are removed the stars will jump about.

What I don't understand is why this needs to be initialised? wouldn't it take its scale directly from the star object?

1 Answer

Steven Parker
Steven Parker
231,269 Points

I don't think it's necessary to set the scale to 1, but that setting also cancels out any other transforms (such as translate) that might otherwise be in effect.