I\'m using the font library font awesome. It works when the project is not built/uglified with grunt.
But when I\'m building the project with grunt it\'s not workin
I was having the very same problem. I took a look a the bower.json file for font-awesome and found this:
{
"name": "font-awesome",
"description": "Font Awesome",
"keywords": [],
"homepage": "http://fontawesome.io",
"dependencies": {},
"devDependencies": {},
"license": ["OFL-1.1", "MIT", "CC-BY-3.0"],
"main": [
"less/font-awesome.less",
"scss/font-awesome.scss"
],
"ignore": [
"*/.*",
"*.json",
"src",
"*.yml",
"Gemfile",
"Gemfile.lock",
"*.md"
]
}
There was no reference to the "font-awesome.css" in the "main" array. Perhaps, like me, you're not using SASS or LESS for styling. So no styles are being added for font-awesome. I modified the json file as follows:
{
"name": "font-awesome",
"description": "Font Awesome",
"keywords": [],
"homepage": "http://fontawesome.io",
"dependencies": {},
"devDependencies": {},
"license": ["OFL-1.1", "MIT", "CC-BY-3.0"],
"main": [
"less/font-awesome.less",
"scss/font-awesome.scss",
"css/font-awesome.css",
"fonts/fontawesome-webfont.tff",
"fonts/fontawesome-webfont.woff",
"fonts/fontawesome-webfont.woff2"
],
"ignore": [
"*/.*",
"*.json",
"src",
"*.yml",
"Gemfile",
"Gemfile.lock",
"*.md"
]
}
I saved and ran grunt serve, and now my font-awesome icons show up.
Hope this helps.