Does removing (or commenting) this line:
$fa-font-path: "../webfonts";
change the situation?
Also can you open your generated css, must be in './public/css/app.scss, search for any @font-face` and post that rule here?
this should be easy but yet its not working for me, i'm using laravel 5.8 to build me app and i need to compile font awesome through npm.
the package is already added to the app but after npm run? it looks like font are missing across my app.
this is my app.scss as per fontawesome documentation
// [email protected]
$fa-font-path: "../webfonts";
@import '~@fortawesome/fontawesome-free/scss/fontawesome.scss';
@import '~@fortawesome/fontawesome-free/scss/solid.scss';
@import '~@fortawesome/fontawesome-free/scss/regular.scss';
@import '~@fortawesome/fontawesome-free/scss/brands.scss';
when i run npm run dev i can't see icons on the front end site neither i can find font folder on the public folder.
on chrome devTools i have this error
Failed to load resource: the server responded with a status of 404 (Not Found)
fa-solid-900.woff2:1 // basically the font is missing ???
// and this error also whitch mean the same
GET http://127.0.0.1:8000/webfonts/fa-solid-900.ttf net::ERR_ABORTED 404 (Not Found)
any ideas on what is going on ???
Weird, the fonts path should be resolved by the sass compiler.
As a workaround add this line to your webpack.mix.js file:
mix.copyDirectory('node_modules/@fortawesome/fontawesome-free/webfonts', 'public/webfonts');
Please or to participate in this conversation.