SVG: Use Attributes or CSS to style?

Viewed 12253

In HTML it is recommended to seperate Content from Style, thus you should create external CSS-Files for your styles. As I am just getting started with SVG I now wonder: Does this rule also apply for SVG?

What is considered better code style?

  • <circle fill="yellow" />
  • or <circle style="fill: yellow;" />
4 Answers
Related