-
gulp-extract-css-urls: 将CSS中包含在url()内的所有资产导入至管道中
资源介绍
Gulp提取CSS URL
将url()随附的所有CSS资产导入管道。
用法
npm install gulp-extract-css-urls --save-dev
import gulp from 'gulp' ;
import extractCssUrls from 'gulp-extract-css-urls' ;
// This will copy main.css along with its resources loaded with url().
gulp . task ( 'default' , ( ) => {
return gulp . src ( 'main.css' , { cwd : 'resources/assets/css/' } )
. pipe ( extractCssUrls ( ) )
. pipe ( g