< Up a Level

Styling code-input elements with CSS

Contributors: 2025 Oliver Geer

code-input elements can be styled like textarea elements in most cases; however, there are some exceptions:

Please do not use className in JavaScript referring to code-input elements, because the code-input library needs to add its own classes to code-input elements for easier progressive enhancement. You can, however, use classList and style as much as you want - it will make your code cleaner anyway.