Aura AuraSubtyped subtype_

subtype_

Returns the definition for a given subtype.

Description

If options are given, sets the options for the given subtype.

This can also be called as an instance method.

Usage

class Page
  subtype NAME,
    :name     => FULL_NAME,
    :template => TEMPLATE
end

Example

Subtype example

This example defines a subtype called 'portfolio'. The template it will use is :page/portfolio.

class Page
  subtype :portfolio,
    :name     => "Portfolio page",
    :template => "portfolio"
end