Browse Source

add test for custom global names for external modules

contingency-plan
Rich Harris 10 years ago
parent
commit
4d6b5de582
  1. 10
      test/form/external-imports-custom-names/_config.js
  2. 5
      test/form/external-imports-custom-names/main.js

10
test/form/external-imports-custom-names/_config.js

@ -0,0 +1,10 @@
module.exports = {
description: 'allows global names to be specified for IIFE/UMD exports',
options: {
external: [ 'jquery' ],
globals: {
jquery: 'jQuery'
}
},
solo: true
};

5
test/form/external-imports-custom-names/main.js

@ -0,0 +1,5 @@
import $ from 'jquery';
$( function () {
$( 'body' ).html( '<h1>hello world!</h1>' );
});
Loading…
Cancel
Save