mirror of
https://github.com/danbulant/api_docs
synced 2026-05-19 04:08:40 +00:00
Fixes #77, update sites without search
Sites without search now do not include search.js or lunr.js, making the javascript for those pages much faster to load.
This commit is contained in:
parent
b363be873b
commit
0aff03f8da
2 changed files with 9 additions and 1 deletions
4
source/javascripts/all_nosearch.js
Normal file
4
source/javascripts/all_nosearch.js
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
//= require_tree ./lib
|
||||
//= require_tree ./app
|
||||
//= stub ./app/search.js
|
||||
//= stub ./lib/lunr.js
|
||||
|
|
@ -24,7 +24,11 @@ under the License.
|
|||
<%= stylesheet_link_tag :screen, media: :screen %>
|
||||
<%= stylesheet_link_tag :print, media: :print %>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
|
||||
<%= javascript_include_tag "all" %>
|
||||
<% if current_page.data.search %>
|
||||
<%= javascript_include_tag "all" %>
|
||||
<% else %>
|
||||
<%= javascript_include_tag "all_nosearch" %>
|
||||
<% end %>
|
||||
|
||||
<% if language_tabs %>
|
||||
<script>
|
||||
|
|
|
|||
Loading…
Reference in a new issue