[extensions-web] Wrap require() calls to DOM.onload
- From: Yuri Konotopov <ykonotopov src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [extensions-web] Wrap require() calls to DOM.onload
- Date: Sat, 3 Dec 2016 09:11:03 +0000 (UTC)
commit 143715b427a020ddca18e107bb3acdab8e039c6e
Author: Yuri Konotopov <ykonotopov gnome org>
Date: Sat Dec 3 12:04:51 2016 +0300
Wrap require() calls to DOM.onload
sweettooth/review/templates/review/review.html | 4 +++-
sweettooth/templates/base.html | 4 +++-
2 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/sweettooth/review/templates/review/review.html b/sweettooth/review/templates/review/review.html
index 507bbfc..95b3b04 100644
--- a/sweettooth/review/templates/review/review.html
+++ b/sweettooth/review/templates/review/review.html
@@ -132,6 +132,8 @@
{{ block.super }}
<link rel="stylesheet" href="/static/css/review.css" />
<script>
- require(['review-main'], function(){});
+ jQuery(function ($) {
+ require(['review-main'], function(){});
+ });
</script>
{% endblock %}
diff --git a/sweettooth/templates/base.html b/sweettooth/templates/base.html
index 9718189..47ecd43 100644
--- a/sweettooth/templates/base.html
+++ b/sweettooth/templates/base.html
@@ -13,7 +13,9 @@
<script src="/static/js/require.js"></script>
<script src="/static/js/jquery.js"></script>
<script>
- require(['main'], function(){});
+ jQuery(function($) {
+ require(['main'], function(){});
+ });
</script>
{% block head %} {% endblock %}
</head>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]