marcj / css-element-queries

CSS Element-Queries aka Container Queries. High-speed element dimension/media queries in valid css.
http://marcj.github.io/css-element-queries/
MIT License
4.27k stars 487 forks source link

Avoid `.innerHTML` sink for Trusted Types compatibility. #315

Open aaronshim opened 2 years ago

aaronshim commented 2 years ago

.innerHTML is considered a HTML injection sink sink in Trusted Types. Replacing .innerHTML with the functionally equivalent .textContent for style elements should avoid Trusted Types violations.