Skip to content

Commit

Permalink
fix(background): set bing background before lazyload initialization
Browse files Browse the repository at this point in the history
  • Loading branch information
koyabr committed Jun 21, 2017
1 parent 9310613 commit 3813036
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions layout/_partial/import_js.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,16 @@
<% if (page.mathjax) { %>
<%- partial('_widget/mathjax') %>
<% } %>

<!-- Bing Background -->
<% if(theme.background.bing.enable) { %>
<script type="text/ls-javascript" id="Bing-Background-script">
queue.offer(function(){
$('body').attr('data-original', 'https://api.i-meto.com/bing?<%= theme.background.bing.parameter %>');
});
</script>
<% } %>

<script type="text/ls-javascript" id="lazy-load">
// Offer LazyLoad
queue.offer(function(){
Expand All @@ -107,15 +117,6 @@
});
</script>

<!-- Bing Background -->
<% if(theme.background.bing.enable) { %>
<script type="text/ls-javascript" id="Bing-Background-script">
queue.offer(function(){
$('body').attr('data-original', 'https://api.i-meto.com/bing?<%= theme.background.bing.parameter %>');
});
</script>
<% } %>

<!-- Custom Footer -->

<% if (site.data.footer) { %>
Expand Down

0 comments on commit 3813036

Please sign in to comment.