Skip to content

Commit 21be39f

Browse files
committed
Exclude jQuery
1 parent 65d84e7 commit 21be39f

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/jqueryui-gridstack-dragdrop-plugin.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import { GridItemHTMLElement } from './types';
1212

1313
// TODO: TEMPORARY until can remove jquery-ui drag&drop and this class and use HTML5 instead !
1414
// see https://stackoverflow.com/questions/35345760/importing-jqueryui-with-typescript-and-requirejs
15-
import * as $ from './jquery.js';
15+
import * as $ from 'jquery';
1616
import './jquery-ui.js';
1717

1818
/**
@@ -110,4 +110,4 @@ JQueryUIGridStackDragDropPlugin.prototype.constructor = JQueryUIGridStackDragDro
110110
....
111111
scope.JQueryUIGridStackDragDropPlugin = JQueryUIGridStackDragDropPlugin;
112112
return JQueryUIGridStackDragDropPlugin;
113-
*/
113+
*/

webpack.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ module.exports = {
55
'gridstack-all': './src/index.ts',
66
'gridstack-no-jquery': './src/gridstack-only.ts'
77
},
8+
externals: {
9+
jquery: 'jQuery'
10+
},
811
mode: 'development',
912
module: {
1013
rules: [

0 commit comments

Comments
 (0)