npm

Ready to take your JavaScript development to the next level? Meet npm Enterprise - the ultimate in enterprise JavaScript.Learn more »

gulp-requirerc

1.0.0 • Public • Published

gulp-requirerc

Gulp adapter for RequireJS

dependencies status devDependency status

Installation

from github:

npm i -D adriancmiranda/gulp-requirerc

from npmjs:

npm i -D gulp-requirerc

Usage

// Gulp adapter for RequireJS
// @see https://github.com/adriancmiranda/gulp-requirerc
var requirerc = require('gulp-requirerc');
 
// All configuration options.
// @see https://github.com/requirejs/r.js/blob/master/build/example.build.js
gulp.task('scripts', function(){
  return gulp.src('source/scripts/*.js').pipe(requirerc({
    baseUrl:'static/scripts',
    uglify2:{ warnings:true },
    optimize:'uglify2',
    generateSourceMaps:true,
    preview:true, // extra option
    outDir:'bundle', // extra option
    outSuffix:'.min' // extra option
  }));
});

Options

Type: Object

options.preview

Type: Boolean Default: true

options.outDir

Type: string Default: ''

options.suffix

Type: string Default: '.bundle'

License

MIT

install

npm i gulp-requirerc

Downloadsweekly downloads

1

version

1.0.0

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability