]> source.dussan.org Git - jquery-ui.git/commitdiff
Widget: Update demo to use AMD
authorAlexander Schmitz <arschmitz@gmail.com>
Wed, 1 Jul 2015 03:46:37 +0000 (23:46 -0400)
committerAlexander Schmitz <arschmitz@gmail.com>
Tue, 21 Jul 2015 15:00:42 +0000 (11:00 -0400)
Ref #10119

demos/widget/default.html

index 62a373114cccfcb9d6cdcc244d1079f75c1eaa41..e545ef6adf2e0cc24d2ee1fa44e7da7bb5664b9a 100644 (file)
@@ -4,11 +4,6 @@
        <meta charset="utf-8">
        <title>jQuery UI Widget - Default functionality</title>
        <link rel="stylesheet" href="../../themes/base/all.css">
-       <script src="../../external/jquery/jquery.js"></script>
-       <script src="../../ui/core.js"></script>
-       <script src="../../ui/position.js"></script>
-       <script src="../../ui/widget.js"></script>
-       <script src="../../ui/button.js"></script>
        <link rel="stylesheet" href="../demos.css">
        <style>
        .custom-colorize {
@@ -24,8 +19,8 @@
                bottom: 0;
        }
        </style>
-       <script>
-       $(function() {
+       <script src="../../external/requirejs/require.js"></script>
+       <script src="../bootstrap.js" data-modules="button">
                // the widget definition, where "custom" is the namespace,
                // "colorize" the widget name
                $.widget( "custom.colorize", {
                                blue: 8
                        });
                });
-       });
        </script>
 </head>
 <body>