Module: Middleman::Sitemap::InstanceMethods
- Defined in:
- lib/middleman-core/sitemap.rb
Overview
Sitemap instance methods
Instance Method Summary collapse
-
#current_page ⇒ Middleman::Sitemap::Resource
Get the resource object for the current path.
-
#current_resource ⇒ Middleman::Sitemap::Resource
Get the resource object for the current path.
-
#sitemap ⇒ Middleman::Sitemap::Store
Get the sitemap class instance.
Instance Method Details
#current_page ⇒ Middleman::Sitemap::Resource
Get the resource object for the current path
70 71 72 |
# File 'lib/middleman-core/sitemap.rb', line 70 def current_page current_resource end |
#current_resource ⇒ Middleman::Sitemap::Resource
Get the resource object for the current path
76 77 78 79 |
# File 'lib/middleman-core/sitemap.rb', line 76 def current_resource return nil unless current_path sitemap.find_resource_by_destination_path(current_path) end |
#sitemap ⇒ Middleman::Sitemap::Store
Get the sitemap class instance
64 65 66 |
# File 'lib/middleman-core/sitemap.rb', line 64 def sitemap @_sitemap ||= Store.new(self) end |