This is my HTML:
<a class="iconContainer" href="#">
<span class="containerIcon chevron-right"/>
Test
</a>
And this is my css:
.chevron-right::before {
display: inline-block;
content: "";
background-image: url("data:image/svg+xml,<svg width='1em' height='1em' viewBox='0 0 16 16' class='bi bi-chevron-right' fill='currentColor' xmlns='http://www.w3.org/2000/svg'><path fill-rule='evenodd' d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/></svg>");
background-repeat: no-repeat;
background-size: 10px 10px;
}
For some reason the icon is not being displayed. This is almost similar to the example shown in the documentation for bootstrap icons here: https://icons.getbootstrap.com/#usage
Does anyone have any insight into what I'm doing wrong? I imagine I'm missing something very obvious. Here is the jsFiddle link for it. https://jsfiddle.net/w5bvs7n6/8/
Edit: I imagine this has to do with content being empty but I'm clueless how it would work if it wasn't.