Comparing version 0.6.26 to 0.6.27
@@ -95,19 +95,21 @@ var path = require( 'path' ), | ||
// transpile all the things | ||
return sander.lsr( options.input ).then( function ( files ) { | ||
var promises = files.map( function ( file ) { | ||
var input = path.join( options.input, file ); | ||
var output = path.join( options.output, file ); | ||
return sander.lsr( options.input ) | ||
.then( filterOutNonJs ) | ||
.then( function ( files ) { | ||
var promises = files.map( function ( file ) { | ||
var input = path.join( options.input, file ); | ||
var output = path.join( options.output, file ); | ||
var fileOptions = assign( {}, options, { | ||
input: input, | ||
output: output, | ||
sourceMapSource: input, | ||
sourceMapFile: output | ||
var fileOptions = assign( {}, options, { | ||
input: input, | ||
output: output, | ||
sourceMapSource: input, | ||
sourceMapFile: output | ||
}); | ||
return convert( fileOptions, method ); | ||
}); | ||
return convert( fileOptions, method ); | ||
return Promise.all( promises ); | ||
}); | ||
return Promise.all( promises ); | ||
}); | ||
} | ||
@@ -189,1 +191,8 @@ | ||
} | ||
function filterOutNonJs ( files ) { | ||
var isJs = /\.js$/; | ||
return files.filter( function ( file ) { | ||
return isJs.test( file ); | ||
}); | ||
} |
# changelog | ||
## 0.6.27 | ||
* AST can be supplied when doing one-to-one transformations (e.g. `esperanto.toAmd({ code, ast })`) ([#140](https://github.com/esperantojs/esperanto/issues/140)) | ||
* Modules can be supplied directly when bundling, rather than reading from disk ([docs here](https://github.com/esperantojs/esperanto/wiki/Bundling-multiple-ES6-modules#modules)) ([#140](https://github.com/esperantojs/esperanto/issues/140)) | ||
* 'use strict' pragma is omitted if `useStrict: false` option is supplied ([#141](https://github.com/esperantojs/esperanto/issues/141)) | ||
## 0.6.26 | ||
@@ -4,0 +10,0 @@ |
{ | ||
"name": "esperanto", | ||
"description": "An easier way to convert ES6 modules to AMD and CommonJS", | ||
"version": "0.6.26", | ||
"version": "0.6.27", | ||
"author": "Rich Harris", | ||
@@ -6,0 +6,0 @@ "repository": "https://github.com/esperantojs/esperanto", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
162209
4464