mirror of https://github.com/lukechilds/rollup.git
Rich Harris
9 years ago
5 changed files with 24 additions and 4 deletions
@ -0,0 +1,15 @@ |
|||||
|
module.exports = { |
||||
|
description: 'does not attempt to resolve external IDs', |
||||
|
options: { |
||||
|
external: [ 'external' ], |
||||
|
plugins: [ |
||||
|
{ |
||||
|
resolveId: function ( importee ) { |
||||
|
if ( importee === 'external' ) { |
||||
|
throw new Error( 'Attempted to resolve external module ID' ); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
] |
||||
|
} |
||||
|
}; |
@ -0,0 +1,2 @@ |
|||||
|
import foo from 'external'; |
||||
|
assert.ok( foo.external ); |
@ -0,0 +1,3 @@ |
|||||
|
module.exports = { |
||||
|
external: true |
||||
|
}; |
Loading…
Reference in new issue