Closed epull closed 2 years ago
Hi,
I have issue for build external fonts 'Lato', I've try add function for moving fonts folder from 'src' to 'dist' folder :
function devFonts(){ return src(${options.paths.src.fonts}/*/).pipe(dest(options.paths.dist.fonts)); }
function devFonts(){ return src(
).pipe(dest(options.paths.dist.fonts)); }
function prodFonts(){ return src(options.paths.src.fonts + '/**/*').pipe(dest(options.paths.build.fonts)); }
and then
exports.default = series( devClean, // Clean Dist Folder parallel(devStyles, devScripts, devImages, devFonts, devHTML), //Run All tasks in parallel livePreview, // Live Preview Build watchFiles // Watch for Live Changes );
exports.prod = series( prodClean, // Clean Build Folder parallel(prodStyles, prodScripts, prodImages, prodFonts, prodHTML), //Run All tasks in parallel buildFinish );
path inside folder src is : src/fonts/lato/xxx.x
I've preview html on dist and build folder but Lato fonts not loaded.
It depends entirely on setup and how you import the fonts in your HTML file. Share the folder structure so i can suggest you
Hi,
I have issue for build external fonts 'Lato', I've try add function for moving fonts folder from 'src' to 'dist' folder :
function devFonts(){ return src(
${options.paths.src.fonts}/*/).pipe(dest(options.paths.dist.fonts)); }
function prodFonts(){ return src(options.paths.src.fonts + '/**/*').pipe(dest(options.paths.build.fonts)); }
and then
exports.default = series( devClean, // Clean Dist Folder parallel(devStyles, devScripts, devImages, devFonts, devHTML), //Run All tasks in parallel livePreview, // Live Preview Build watchFiles // Watch for Live Changes );
exports.prod = series( prodClean, // Clean Build Folder parallel(prodStyles, prodScripts, prodImages, prodFonts, prodHTML), //Run All tasks in parallel buildFinish );
path inside folder src is : src/fonts/lato/xxx.x
I've preview html on dist and build folder but Lato fonts not loaded.