about summary refs log tree commit diff
path: root/app/assets/javascripts
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2016-03-25 15:09:40 +0100
committerEugen Rochko <eugen@zeonfederated.com>2016-03-25 15:09:40 +0100
commit318886287b289a8caccf19102da8584453ef7faa (patch)
treeb3cf78d9c9b52c750aa3539072158fc49081c9e6 /app/assets/javascripts
parent36f3da3cde2bc2148e156a5dd09d732a06b44ddd (diff)
Fixing some stuff for Turbolinks, adding gzip on top, fixing a n+1 query
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r--app/assets/javascripts/mastodon-logo.coffee2
-rw-r--r--app/assets/javascripts/profiler.coffee2
2 files changed, 3 insertions, 1 deletions
diff --git a/app/assets/javascripts/mastodon-logo.coffee b/app/assets/javascripts/mastodon-logo.coffee
index bcf52f378..0b4e67e79 100644
--- a/app/assets/javascripts/mastodon-logo.coffee
+++ b/app/assets/javascripts/mastodon-logo.coffee
@@ -44,5 +44,5 @@ work = ->
   if runs == stop_at_run
     stop()
 
-$ ->
+$(document).on 'turbolinks:load', ->
   setTimeout(start, 100)
diff --git a/app/assets/javascripts/profiler.coffee b/app/assets/javascripts/profiler.coffee
new file mode 100644
index 000000000..bcdcc1e59
--- /dev/null
+++ b/app/assets/javascripts/profiler.coffee
@@ -0,0 +1,2 @@
+$(document).on 'turbolinks:load', ->
+  window.MiniProfiler.pageTransition() unless typeof window.MiniProfiler == 'undefined'