SVG: Code-Based, Infinitely Scalable Graphics

Think of SVG as HTML for graphics. It's an XML file with drawing instructions, not pixels, so images scale perfectly. It's ideal for logos and icons on responsive sites. The footgun: SVGs can contain JavaScript, posing a security risk (XSS) if not sanitized.
Think of SVG as HTML for graphics. It's a text-based XML file containing drawing instructions, not a grid of pixels like a JPG. This allows it to scale infinitely without losing quality, making it perfectly sharp on any screen. It's essential for responsive design, used for logos, icons, and dynamic data visualizations that can be manipulated with CSS and JavaScript. The footgun: forgetting SVGs are live documents.
Read the original → developer.mozilla.org
- #svg
- #vector graphics
- #ui
- #frontend
Get five bites like this every day.
Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.