From 391dee5c981a3c164aea55d0b4ce9009648df46a Mon Sep 17 00:00:00 2001 From: Rich-Harris Date: Sun, 19 Jun 2016 13:17:48 -0400 Subject: [PATCH 1/3] fix test --- test/sourcemaps/loaders/_config.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/test/sourcemaps/loaders/_config.js b/test/sourcemaps/loaders/_config.js index 8665133..53bae64 100644 --- a/test/sourcemaps/loaders/_config.js +++ b/test/sourcemaps/loaders/_config.js @@ -1,4 +1,4 @@ -var babel = require( 'babel-core' ); +var buble = require( 'buble' ); var fs = require( 'fs' ); var assert = require( 'assert' ); var getLocation = require( '../../utils/getLocation' ); @@ -16,10 +16,12 @@ module.exports = { id = id.replace( /bar.js$/, 'foo.js' ); } - var out = babel.transformFileSync( id, { - blacklist: [ 'es6.modules' ], + var code = fs.readFileSync( id, 'utf-8' ); + + var out = buble.transform( code, { + transforms: { modules: false }, sourceMap: true, - comments: false // misalign the columns + source: id }); if ( /main.js$/.test( id ) ) { From 6b1ac41bdc0131ef8a333700048ad065427ab8c2 Mon Sep 17 00:00:00 2001 From: Rich-Harris Date: Sun, 19 Jun 2016 13:18:02 -0400 Subject: [PATCH 2/3] update self-dependency, move to es format --- package.json | 2 +- rollup.config.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index de52c12..13d1692 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,7 @@ "mocha": "^2.5.3", "remap-istanbul": "^0.6.4", "require-relative": "^0.8.7", - "rollup": "^0.31.2", + "rollup": "^0.32.0", "rollup-plugin-buble": "^0.11.0", "rollup-plugin-commonjs": "^3.0.0", "rollup-plugin-json": "^2.0.0", diff --git a/rollup.config.js b/rollup.config.js index bfd6e83..bac62f2 100644 --- a/rollup.config.js +++ b/rollup.config.js @@ -42,6 +42,6 @@ export default { moduleName: 'rollup', targets: [ { dest: 'dist/rollup.js', format: 'cjs' }, - { dest: 'dist/rollup.es.js', format: 'es6' } + { dest: 'dist/rollup.es.js', format: 'es' } ] }; From 9454281953fce3472460421ec5d4a779ed76cac1 Mon Sep 17 00:00:00 2001 From: Rich-Harris Date: Sun, 19 Jun 2016 13:19:11 -0400 Subject: [PATCH 3/3] remove unused promise helper --- browser/promise.js | 1 - rollup.config.browser.js | 1 - 2 files changed, 2 deletions(-) delete mode 100644 browser/promise.js diff --git a/browser/promise.js b/browser/promise.js deleted file mode 100644 index 06b8309..0000000 --- a/browser/promise.js +++ /dev/null @@ -1 +0,0 @@ -export default window.Promise; diff --git a/rollup.config.browser.js b/rollup.config.browser.js index adee949..86a0985 100644 --- a/rollup.config.browser.js +++ b/rollup.config.browser.js @@ -4,7 +4,6 @@ import config from './rollup.config.js'; config.plugins.push({ load: function ( id ) { if ( ~id.indexOf( 'fs.js' ) ) return readFileSync( 'browser/fs.js' ).toString(); - if ( ~id.indexOf( 'es6-promise' ) ) return readFileSync( 'browser/promise.js' ).toString(); } });