Does anyone know the correct way to setup a Hugo, using PostCSS to move fonts into public when building - but also be served locally in memory when running in local dev server?
I want to use some fonts from my FA pro sub, so have set up my css file to import them and then I have tried postcss-url but that seems to only want to copy the files to a location, then the pathing doesn’t work. Manually setting up a copy to public will get out of hand and then would’t work for local dev.
Thanks - but that seems to just talk about the asset compiling, which is all working. Just not sure on the configuration for the moving/extraction of the embedded assets in the css. I think the config will need to be done in the postcss config file
Ahh I see. I’m getting the fonts via their npm package, and having an @import line in my css file. So the fonts are actually relative to their location in the node modules folder. I want to avoid a manual copy of them into the assets folder and having them source controlled.
The PostCSS config is correctly importing the css - however the fonts are left behind in the node modules folder in both dev and prod mode.