Icon font from fontello not working with Meteor js

后端 未结 3 1945
孤城傲影
孤城傲影 2021-01-22 12:05

I have downloaded a custom icon font from fontello and intend to use it in my meteor app. I tried the demo that comes with the downloaded package and the fonts display fine. He

3条回答
  •  刺人心
    刺人心 (楼主)
    2021-01-22 12:46

    If you want to reference your fonts at your.domain.com/fonts/font_name.x, you should move your fonts directory to a directory labeled public. You can then access them using the path /fonts/font_name.x.

    Take a look at the Unofficial Meteor FAQ found here: https://github.com/oortcloud/unofficial-meteor-faq#where-should-i-put-my-files

    public/ # <- static files, such as images, that are served directly.

    Or the Meteor documentation directly: http://docs.meteor.com/#structuringyourapp

    Lastly, the Meteor server will serve any files under the public directory, just like in a Rails or Django project. This is the place for images, favicon.ico, robots.txt, and anything else.

提交回复
热议问题