I would like to know how to add a local font to the solution.
I can see that the webpack.common.js differs from the one used in Litium 7 (where I can do it successfully), for example the function CopyWebpackPlugin seems to be missing.
So my question is how do I configure the webpack.common.js file so that we can host local fonts in our solution?
PS: There‘s no “fonts folder” in the wwwroot/ui folder either.
I can also see that the fonts from my clients/fonts folder are being placed in the es6 folder in wwwroot/ui. Not sure if they are supposed to be there , but it feels out of place. They are placed there after a yarn build
I found out that it only works if i use type: ‘asset/inline’ instead of ‘asset/resource’. If I use the latter, I get an error in the browser stating the following:
“Not allowed to load local resource: file:///D:/ui/es6/f871baa12f2df527c345.ttf”
Hi Ton!
Thank you for your response, unfortunatly it didn’t work with the upgrade.
As soon as I have it as an assets/resource, all browsers complain that the local resource is not allowed. And what I find odd is that the url to the font file in this case goes to my local “D”-disc, not sure is this is the way it’s supposed to be.
I would also like to point out that this issue is present with every Litium 8 project we currently run, so the matter is quite urgent.
Thank you again for you continued support and help