Improve partial rendering and Haml performance (Haml->Hamlit)
This commit is contained in:
parent
95d72b2249
commit
57583f3fb8
5 changed files with 13 additions and 22 deletions
|
@ -5,10 +5,9 @@
|
|||
= render partial: 'header'
|
||||
|
||||
.accounts-grid
|
||||
- @followers.each do |f|
|
||||
= render partial: 'grid_card', locals: { account: f }
|
||||
|
||||
- if @followers.empty?
|
||||
= render partial: 'nothing_here'
|
||||
- else
|
||||
= render partial: 'grid_card', collection: @followers, as: :account
|
||||
|
||||
= will_paginate @followers, pagination_options
|
||||
|
|
|
@ -6,10 +6,9 @@
|
|||
= render partial: 'header'
|
||||
|
||||
.accounts-grid
|
||||
- @following.each do |f|
|
||||
= render partial: 'grid_card', locals: { account: f }
|
||||
|
||||
- if @following.empty?
|
||||
= render partial: 'nothing_here'
|
||||
- else
|
||||
= render partial: 'grid_card', collection: @following, as: :account
|
||||
|
||||
= will_paginate @following, pagination_options
|
||||
|
|
|
@ -12,7 +12,6 @@
|
|||
= render partial: 'nothing_here'
|
||||
- else
|
||||
.activity-stream
|
||||
- @statuses.each do |status|
|
||||
= render partial: 'stream_entries/status', locals: { status: status }
|
||||
= render partial: 'stream_entries/status', collection: @statuses, as: :status
|
||||
|
||||
= will_paginate @statuses, pagination_options
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue