Browse Source

windows fix?

gh-438-b
Rich Harris 9 years ago
parent
commit
283eefa946
  1. 6
      src/Bundle.js

6
src/Bundle.js

@ -59,7 +59,7 @@ export default class Bundle {
this.assumedGlobals = blank();
this.external = options.external || [];
this.external = ensureArray( options.external ).map( id => id.replace( /[\/\\]/g, '/' ) );
this.onwarn = options.onwarn || makeOnwarn();
// TODO strictly speaking, this only applies with non-ES6, non-default-only bundles
@ -172,8 +172,8 @@ export default class Bundle {
const promises = module.dependencies.map( source => {
return Promise.resolve( this.resolveId( source, module.id ) )
.then( resolvedId => {
// If the `resolvedId` is supposed to be exteral, make it so.
const forcedExternal = ~this.external.indexOf( resolvedId );
// If the `resolvedId` is supposed to be external, make it so.
const forcedExternal = ~this.external.indexOf( resolvedId.replace( /[\/\\]/g, '/' ) );
if ( !resolvedId || forcedExternal ) {
if ( !forcedExternal ) {

Loading…
Cancel
Save