RickStrahl/jquery-resizable

Version 0.20.0 CommonJs problem

romero83 opened this issue · 0 comments

Hi,

I just upgraded from version 0.18.0 to 0.20.0 and my application broke.
Error message: .resizable is not a function
I use CommonJs for internal module import. I imported jQuery without CommonJs from outside:

index.html

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <title>Test page</title>
</head>
<body>
  <div id="panel">
    <div id="list"></div>
    <div class="win-size-grip"><i class="fa fa-signal"></i></div>
  </div>

<script>
  <script src="resources/jquery/jquery.js"></script>
  <script src="index.js"></script>
</script>
</body>
</html>

index.js:

(function($) {
 'use strict';

  global.jQuery = $;

  require('myApplication/testEvent');
})(window.$);

testEvent.js

(function($) {
 'use strict';

require('jquery-resizable-dom');

$('#panel').resizable({
            handleSelector: ".win-size-grip",
            onDrag: function(e, $el, newWidth, newHeight) {
                $("#list").height(newHeight - 140).width(newWidth / 2 - 30);
            }
        });

})(window.$);

What is the problem? Did I miss something?
When I using version 0.18.0 it is working fine.

Thank you,
Best regards,
Rómeó Nagy