Performance: String types and concatenation
MEDIUM IMPACT
This affects CSS generation speed and final CSS file size, impacting page load and render time.
$color: "red blue green";
$color: "red" + " " + "blue" + " " + "green";
| Pattern | DOM Operations | Reflows | Paint Cost | Verdict |
|---|---|---|---|---|
| Multiple '+' concatenations in Sass | 0 (preprocessing only) | 0 | 0 | [X] Bad |
| Single string literal | 0 | 0 | 0 | [OK] Good |
| Interpolation with #{} | 0 | 0 | 0 | [OK] Good |