Tsallaka zuwa abun ciki
Justice Tech School

Customising with CSS Variables

Override CSS variables to restyle components.

Example
<style>
  :root { --bs-primary: #7c3aed; --bs-primary-rgb: 124,58,237; }
  .btn-primary { --bs-btn-bg: #7c3aed; --bs-btn-border-color: #7c3aed; }
</style>

Exercise

Variable prefix.

---primary

Quiz Test

What are --bs-* values?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.