فهرست منبع

[metastore] Fix issue with load order for the ko.hue-bindings

The load of all the "require" modules are async, any module that requires a defined module will wait for it to load before loading.
Johan Ahlen 10 سال پیش
والد
کامیت
50bc21b
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      desktop/core/src/desktop/static/desktop/js/ko.hue-bindings.js

+ 2 - 2
desktop/core/src/desktop/static/desktop/js/ko.hue-bindings.js

@@ -15,8 +15,8 @@
 // limitations under the License.
 
 (function (factory) {
-  if(typeof require === "function") {
-    require(['knockout'], factory);
+  if(typeof define === "function") {
+    define("ko.hue-bindings", ["knockout"], factory);
   } else {
     factory(ko);
   }