A
A
ayapergenov2016-02-15 09:10:03
gulp.js
ayapergenov, 2016-02-15 09:10:03

Why are fonts not included via Gulp?

I registered pipe in gulpfile.js, but the folder with fonts is not copied to the build folder.

gulp.task('fonts', function() {
  return gulp.src('./assets/fonts/*') // записываем путь исходной папке
  .pipe(gulp.dest('./build/fonts/')) // записываем фрифты
});

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
ayapergenov, 2016-02-15
@ayapergenov

The problem was solved by the author of the assembly, after contacting github

// Копируем шрифты

gulp.task('fonts:copy', function() { 
    gulp.src('./assets/fonts/**/*.{eot,svg,ttf,woff,woff2}') 
        .pipe(gulp.dest('./public/fonts/')); 
});

O
Oleg, 2016-02-15
@werty1001

Try like this:

gulp.task('fonts:copy', function() {
  return gulp.src('./assets/fonts/**/*.{eot,svg,ttf,woff,woff2}').pipe(gulp.dest('./build/fonts/'));
});

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question