Yeoman,如何引用凉亭包(font-awesome)? [英] Yeoman, How to reference a bower package (font-awesome)?

查看:99
本文介绍了Yeoman,如何引用凉亭包(font-awesome)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对Yeoman完全陌生,在设置我的项目后面临
的问题我决定使用font-awesome
,所以我使用了bower和它来安装它工作正常



问题是font-awesome不在dist / bower_components文件夹中
,但是当我在html中引用font-awesome的css文件时像这样的页面

 < link rel =stylesheethref =bower_components / font-awesome / css / font-awesome。 CSS> 

它可以在localhost中运行,但dist / bower_components中除了requirejs之外,其它文件仍然没有。



那么我该如何告诉grunt将font-awesome的文件复制到dist / bower_components文件夹? 解决方案

我会使用 Grunt-Contrib-Copy 为您复制该文件夹。


I'm totally new to Yeoman and I'm facing an issue with it after setting up my project I decided that I want to use font-awesome so I installed it using bower and it works fine

the issue is that font-awesome is not in the dist/bower_components folder but when I reference the css file of font-awesome in the html page like this

<link rel="stylesheet" href="bower_components/font-awesome/css/font-awesome.css">

it works in the localhost but still no files in dist/bower_components except for requirejs

so how can I tell grunt to copy font-awesome's files to the dist/bower_components folder ?

解决方案

I would use Grunt-Contrib-Copy to copy that folder for you.

这篇关于Yeoman,如何引用凉亭包(font-awesome)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆