Topic: Changing directory reference for font files
Lucy Barber free asked 5 years ago
When I ran the npm install commands for the angular mdb project, it added all the fontawesome and roboto font files to the folder that is listed in my angular.json file as the outputPath (dist). When I ran the application, I got 404 Not Found errors on those font files because the base href of the application was not set to the dist folder. When I changed the base href to reference the dist folder, the font files loaded without issue. The problem is, I can't have the base href set to that folder as I need it configured to a specific location in order for routing on my app to work.
I'm not sure how to change the directory lookup so that even if my base href is not set to my dist folder the font files will load. Is there a way to make it so that the importing the font files is not using the base href to look it up?
Damian Gemza staff answered 5 years ago
Dear Lucy,
Could you please provide me with reproduction steps? How can I reproduce your problem?
Without that information, I won't be able to help you well, because I have to debug your problem, and test something.
Best Regards,
Damian
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- ForumUser: Free
- Premium support: No
- Technology: MDB Angular
- MDB Version: 7.4.3
- Device: MacBook Pro
- Browser: Chrome
- OS: macOS Mojave
- Provided sample code: No
- Provided link: No