D
D
drtvader2017-10-09 10:00:16
Sass
drtvader, 2017-10-09 10:00:16

How to include icon font in scss?

Hey!
Faced a problem, I can not set the icon font. The assembly throws off the error, apparently the wrong syntax.

@font-face {
  font-family: "icons";
  src: url('../fonts/icons.eot');
  src: url('../fonts/icons.eot?#iefix') format('eot'),
    url('../fonts/icons.woff2') format('woff2'),
    url('../fonts/icons.woff') format('woff'),
    url('../fonts/icons.ttf') format('truetype'),
    url('../fonts/icons.svg#icons') format('svg');
}

.icon-base-pseudo {
  font-family: "icons";
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  font-style: normal;
  font-variant: normal;
  font-weight: normal;
  // speak: none; // only necessary if not using the private unicode range (firstGlyph option)
  text-decoration: none;
  text-transform: none;
}

.icon-char(@filename) {
  $close: "\E001";
  $pay-icon-blue: "\E002";
  $pay-icon-orange: "\E003";
  $search: "\E004";
  $sort: "\E005";
  content: @@filename;
}

What's wrong? or where to look?
Building with less works fine, but I can't set it up in scss.
gulp-iconfont and gulp-iconfont-css are installed.
Screenshot of the error

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question