Interview Question

What is rotate in CSS?

rotate turns an element around its transform origin.

💡 Concept ✅ Quick Revision 🎨 CSS

Answer

Rotation turns an element around a transform origin. • Angles can use deg, rad, grad, or turn units. • The transform-origin property controls the pivot point. • Rotation changes painting and hit testing but not normal-flow dimensions.

💡 Simple Example

.icon { transform: rotate(45deg); }

⚡ Quick Revision

rotate turns an element around its transform origin.