# Extend built-in css class

**URL:** <https://forum.inductiveautomation.com/t/extend-built-in-css-class/69105>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [January 27, 2023, 5:57pm UTC](https://forum.inductiveautomation.com/t/extend-built-in-css-class/69105 "2023-01-27T17:57:55Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michael\_White](https://avatars.discourse-cdn.com/v4/letter/m/c6cbf5/32.png) [@Michael\_White](https://forum.inductiveautomation.com/u/Michael_White)\
**Post date:** [January 27, 2023, 5:57pm UTC](https://forum.inductiveautomation.com/t/extend-built-in-css-class/69105/1 "2023-01-27T17:57:55Z")

</div>

Is it possible to override/extend built-in css classes?

Like for example, if I wanted to add more to the `ia_toggleSwitch` class, is there a best practices way to do so?

---

<div class="post-metadata">

**Author:** ![dkhayes117](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/dkhayes117/32/68344_2.png) [@dkhayes117](https://forum.inductiveautomation.com/u/dkhayes117)\
**Post date:** [January 27, 2023, 5:59pm UTC](https://forum.inductiveautomation.com/t/extend-built-in-css-class/69105/2 "2023-01-27T17:59:51Z")

</div>

This thread has a little more information on that. A bit of searching and you should find more advice on the forum 🙂  
[Perspective Table: Create a Style Class that Contains Multiple Style Settings - Ignition - Inductive Automation Forum](https://forum.inductiveautomation.com/t/perspective-table-create-a-style-class-that-contains-multiple-style-settings/69047)

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [January 27, 2023, 6:30pm UTC](https://forum.inductiveautomation.com/t/extend-built-in-css-class/69105/3 "2023-01-27T18:30:59Z")

</div>

Note that despite often being referred to as _classes_, what you actually write in CSS is almost entirely _selectors_.  
There's no composition or inheritance [1] in CSS - any number of selectors can be written and they will all apply to the elements. So you can just write _your own selector_ that does whatever you want it to do.

[1]. Okay, _technically_ there's inheritance, sort of, in two ways - the order files are loaded in matters, and the 'most specific' selector wins. But it's more important to not think about CSS selectors as being something you need to "extend" - you just write a new selector and be on your way.
