about summary refs log tree commit diff
path: root/app/helpers
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2016-09-13 02:24:40 +0200
committerEugen Rochko <eugen@zeonfederated.com>2016-09-13 02:24:40 +0200
commit2e7aac793ace0e938e45cb54ff601afa5d872214 (patch)
tree5c45c25a21ef9b1068604b8c459e1855ba91f239 /app/helpers
parentd6a64f45fd4530cfee4f7721f0c6e7ca28fe677f (diff)
Adding sense of self to the UI, cleaning up routing, adding third (detail) column
Diffstat (limited to 'app/helpers')
-rw-r--r--app/helpers/home_helper.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/app/helpers/home_helper.rb b/app/helpers/home_helper.rb
index 23de56ac6..d08264e1e 100644
--- a/app/helpers/home_helper.rb
+++ b/app/helpers/home_helper.rb
@@ -1,2 +1,14 @@
 module HomeHelper
+  def default_props
+    {
+      token: @token,
+
+      account: render(file: 'api/accounts/show', locals: { account: current_user.account }, formats: :json),
+
+      timelines: {
+        home: render(file: 'api/statuses/home', locals: { statuses: @home }, formats: :json),
+        mentions: render(file: 'api/statuses/mentions', locals: { statuses: @mentions }, formats: :json)
+      }
+    }
+  end
 end