Error: Getting 404 for all the web fonts woff woff2 ttf files for angular editor.
Solution: Add the following section in assets configuration in angular.json file of your project:
{
"glob": "**/*",
"input": "./node_modules/@kolkov/angular-editor/assets/",
"output": "./assets/fonts/"
}
The complete section will look like this:
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "dist/",
"index": "src/index.html",
"main": "src/main.ts",
"polyfills": "src/polyfills.ts",
"tsConfig": "tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": [
"src/favicon.ico",
"src/robots.txt",
"src/assets",
{
"glob": "**/*",
"input": "./node_modules/@kolkov/angular-editor/assets/",
"output": "./assets/fonts/"
}
],
"styles": [
"src/styles.scss"
]
},
Running ng build will have the font awesome files copied to the dist folder at following path: /dist/assets/fonts. The files were copied from ./node_modules/@kolkov/angular-editor/assets/ location at the time of build.