class Nanoc::MutableLayoutCollectionView

Public Instance Methods

create(content, attributes, identifier) click to toggle source

Creates a new layout and adds it to the site’s collection of layouts.

@param [String] content The layout content.

@param [Hash] attributes A hash containing this layout's attributes.

@param [Nanoc::Identifier, String] identifier This layout's identifier.

@return [self]

# File lib/nanoc/base/views/mutable_layout_collection_view.rb, line 17
def create(content, attributes, identifier)
  @objects << Nanoc::Int::Layout.new(content, attributes, identifier)
  self
end
view_class() click to toggle source

@api private

# File lib/nanoc/base/views/mutable_layout_collection_view.rb, line 4
def view_class
  Nanoc::MutableLayoutView
end