Stencil version: @stencil/core@1.3.0
I want to use Font Awesome inside my Stencil component.
I followed these steps from https://fontawesome.com/how-to-use/on-the-web/setup/using-package-managers
npm install --save-dev @fortawesome/fontawesome-free
src/index.html
:<script src="../node_modules/@fortawesome/fontawesome-free/css/all.css"></script>
<script src="../node_modules/@fortawesome/fontawesome-free/js/all.js"></script>
render() {
return (
<button>
<i class="fas fa-camera"></i>
</button>
);
}
I'm not able to include font awesome inside my stencil component. I'm stuck here: <i class="fas fa-camera"></i>
Basically this problem is not only related to font-awesome and stenciljs its a general "custom-font" with "web-components" problem. Here is a link to the thread with working solution. I Tried it out by myself works perfectly.