所以我有我的 svg 图像,我想使用 Fontello 将其转换为图标并将其导入我的 nuxt 项目。但配置似乎不起作用
这就是我的nuxt.config.js文件中的内容
head: {
css: [
'~/assets/css/main.css',
'~/assets/css/animation.css',
'~/assets/css/fontello.css',
'~/assets/css/fontello-ie7.css',
'~/assets/css/fontello-ie7-codes.css', /*if IE 7 */
],
}
在我的 html 页面中,我正在使用
<i @click="goToChat" class="the-icons demo-icon icon-chat menu ic-menu"></i>
和我的css文件,
.demo-icon {
font-family: "fontello";
font-style: normal;
font-weight: normal;
speak: none;
display: inline-block;
text-decoration: inherit;
width: 1em;
margin-right: 0.2em;
text-align: center;
font-variant: normal;
text-transform: none;
line-height: 1em;
margin-left: 0.2em;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
问题是css文件无法读取font-family: "fontello";
我配置错了吗?