updated dist build process
This commit is contained in:
		
							parent
							
								
									d1e30c5040
								
							
						
					
					
						commit
						3faeb628fd
					
				
							
								
								
									
										2
									
								
								dist
									
									
									
									
									
								
							
							
								
								
								
								
								
								
									
									
								
							
						
						
									
										2
									
								
								dist
									
									
									
									
									
								
							@ -1 +1 @@
 | 
			
		||||
Subproject commit dcf62124363cabd3665a2487b8cf18b23c655ba3
 | 
			
		||||
Subproject commit acfce069121920c349b2678b2e1b6d0f1a62b45b
 | 
			
		||||
@ -32,10 +32,10 @@ module.exports = function (gulp, helperOptions) {
 | 
			
		||||
    modules: 'ignore',
 | 
			
		||||
    experimental: true
 | 
			
		||||
  }
 | 
			
		||||
  if (options.regenerator) {
 | 
			
		||||
    files.specs = helperOptions.polyfills.concat(files.specs)
 | 
			
		||||
  } else {
 | 
			
		||||
  if (!options.regenerator) {
 | 
			
		||||
    babelOptions.blacklist = 'regenerator'
 | 
			
		||||
  } else {
 | 
			
		||||
    files.dist = [files.dist].concat(helperOptions.polyfills)
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  gulp.task('dist', function () {
 | 
			
		||||
@ -54,7 +54,7 @@ module.exports = function (gulp, helperOptions) {
 | 
			
		||||
      .pipe(source(options.targetName))
 | 
			
		||||
      .pipe(buffer())
 | 
			
		||||
      .pipe($.if(options.debug, $.sourcemaps.init({loadMaps: true})))
 | 
			
		||||
      .pipe($.if(!options.debug && options.regenerator, $.babel(babelOptions)))
 | 
			
		||||
      .pipe($.if(true, $.babel(babelOptions)))
 | 
			
		||||
      .pipe($.if(!options.debug && options.regenerator, $.uglify()))
 | 
			
		||||
      .pipe($.if(options.debug, $.sourcemaps.write('.')))
 | 
			
		||||
      .pipe(gulp.dest('./dist/'))
 | 
			
		||||
 | 
			
		||||
@ -48,7 +48,7 @@ var $ = require('gulp-load-plugins')()
 | 
			
		||||
var runSequence = require('run-sequence').use(gulp)
 | 
			
		||||
 | 
			
		||||
require('./gulpfile.helper.js')(gulp, {
 | 
			
		||||
  polyfills: [],
 | 
			
		||||
  polyfills: ['node_modules/gulp-babel/node_modules/babel-core/node_modules/regenerator/runtime.js'],
 | 
			
		||||
  entry: './src/y.js',
 | 
			
		||||
  targetName: 'y.js',
 | 
			
		||||
  moduleName: 'yjs',
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user