gulpfile.babel.js
function umd() {
  let bundler = browserify(src, { debug: true, standalone: 'luhn' })
    .transform(babelify) // .configure({ optional: ['runtime'] })
    .bundle();

  return bundler
    .pipe(source(pack.main)) // gives streaming vinyl file object
    .pipe(buffer()) // convert from streaming to buffered vinyl file object
    .pipe(sourcemaps.init({ loadMaps: true })) // loads map from browserify file
    .pipe(sourcemaps.write('./'))
    .pipe(gulp.dest('./'));
}
function umd() {
  let bundler = browserify(src, { debug: true, standalone: 'luhn' })
    .transform(babelify) // .configure({ optional: ['runtime'] })
    .bundle();

  return bundler
    .pipe(source(pack.main)) // gives streaming vinyl file object
    .pipe(buffer()) // convert from streaming to buffered vinyl file object
    .pipe(sourcemaps.init({ loadMaps: true })) // loads map from browserify file
    .pipe(sourcemaps.write('./'))
    .pipe(gulp.dest('./'));
}
function umd ( ) { let bundler = browserify ( src , { debug : true , standalone : 'luhn' } ) . transform ( babelify ) // .configure({ optional: ['runtime'] }) . bundle ( ) ; return bundler . pipe ( source ( pack . main ) ) // gives streaming vinyl file object . pipe ( buffer ( ) ) // convert from streaming to buffered vinyl file object . pipe ( sourcemaps . init ( { loadMaps : true } ) ) // loads map from browserify file . pipe ( sourcemaps . write ( './' ) ) . pipe ( gulp . dest ( './' ) ) ; }
umd standalone library with sourcemaps
umd standalone library with sourcemaps