Skip to content

Latest commit

 

History

History
27 lines (21 loc) · 539 Bytes

File metadata and controls

27 lines (21 loc) · 539 Bytes

gulp-src

A Gulp plugin for get files or dependencies from YAML file (.yml)

Usage in gulpfile.js:

gulp.task('source', function() {
    var sources = gulp.src('source.yml')
        .pipe(source())
        .pipe(gulp.dest('./app'));

    return gulp.src('./app/index.html')
        .pipe(inject(sources, {relative: true}))
        .pipe(gulp.dest('./app'));
});

And in source.yml:

scripts:
  - node_modules/jquery/dist/jquery.min.js

#styles:
  # your stylesheets here...

# you can add any other folder