Skip to content

Input html file(s) and get a stream of all referenced stylesheets which can then be usedfor further processing like concatenation, minification or for testing

License

Notifications You must be signed in to change notification settings

ntvsx193/gulp-stylesheet-index

Repository files navigation

gulp-stylesheet-index NPM version Build Status bitHound Dependencies Coverage percentage

Input html file(s) and get a stream of all referenced stylesheets which can then be usedfor further processing like concatenation, minification or for testing

Clone code from gulp-scripts-index

Install

$ npm install --save-dev gulp-stylesheet-index

Usage

Simple Example

If you simply need all files that are referenced in the index.html and you don't want to use the excellent useref for further processing it is as simple as:

var gsi = require('gulp-stylesheet-index');

gulp.src(['index.html'])
	.pipe(gsi())
	.pipe(doSomethingElse())
	.pipe(gulp.dest('./'))

Options

  • searchPaths {Array} - Defaults to []. this option can be used to specify additional locations in which to look for the script files referenced in index.html. That way, even files that are not stored at the actually specified location can be found and processed. The specified searchpaths are to be defined as relative to the process's cwd.

License

MIT © Artem Kolesnik

About

Input html file(s) and get a stream of all referenced stylesheets which can then be usedfor further processing like concatenation, minification or for testing

Resources

License

Stars

Watchers

Forks

Packages

No packages published