class Jekyll::Drops::SiteDrop
Public Instance Methods
[](key)
click to toggle source
Calls superclass method
Jekyll::Drops::Drop#[]
# File lib/jekyll/drops/site_drop.rb, line 13 def [](key) if @obj.collections.key?(key) && key != "posts" @obj.collections[key].docs else super(key) end end
collections()
click to toggle source
# File lib/jekyll/drops/site_drop.rb, line 29 def collections @site_collections ||= @obj.collections.values.map(&:to_liquid) end
html_pages()
click to toggle source
# File lib/jekyll/drops/site_drop.rb, line 25 def html_pages @site_html_pages ||= @obj.pages.select { |page| page.html? || page.url.end_with?("/") } end
posts()
click to toggle source
# File lib/jekyll/drops/site_drop.rb, line 21 def posts @site_posts ||= @obj.posts.docs.sort { |a, b| b <=> a } end