Normally Pleasant Mixture
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

link-assets

0.0.8 • Public • Published

link-assets v0.0.8 Build Status

Information

Packagelink-assets
Description Spits out a file containing HTML links/scripts for each of the assets given
Node Version >= 0.8

Example usage with Gulp

var gulp = require('gulp');
var linkAssets = require('./');
 
gulp.task('include', function () {
    gulp.src('./css/*.css')
        .pipe(linkAssets('styles.html'))
        .pipe(gulp.dest('./includes/'));
});
 
gulp.task('default', ['include']);

linkAssets(fileName, options)

PropertyDefaultDescription
bustCachefalseA time-based query string will be appended
docRootNonePath to document root so only relative paths to assets are written out. If none is passed, just the filenames are output.
lineBreaksfalseSplits asset references onto separate lines
selfCloseEmptyElementsfalsePuts closing slash on empty elements

Notes

  • Forward slashes are always used no matter which platform.

install

npm i link-assets

Downloadsweekly downloads

1

version

0.0.8

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability