Class: CustomElementsManifestParser::DataTypes::Slot

Inherits:
BaseStruct
  • Object
show all
Defined in:
lib/custom_elements_manifest_parser/data_types/slot.rb

Overview

Documents slots for a custom element

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#deprecatednil, ...

Returns - Whether the slot is deprecated. If the value is a string, it's the reason for the deprecation.

Returns:

  • (nil, Boolean, String)

    - Whether the slot is deprecated. If the value is a string, it's the reason for the deprecation.



24
# File 'lib/custom_elements_manifest_parser/data_types/slot.rb', line 24

attribute :deprecated, Types::Strict::String.optional | Types::Strict::Bool.optional.meta(required: false)

#descriptionString?

Returns - A markdown description.

Returns:

  • (String, nil)
    • A markdown description.


18
# File 'lib/custom_elements_manifest_parser/data_types/slot.rb', line 18

attribute :description, Types::Strict::String.optional.meta(required: false)

#nameString

Returns - The slot name, or the empty string for an unnamed slot.

Returns:

  • (String)
    • The slot name, or the empty string for an unnamed slot.


10
# File 'lib/custom_elements_manifest_parser/data_types/slot.rb', line 10

attribute :name, Types::Strict::String

#summaryString?

Returns - A markdown summary suitable for display in a listing.

Returns:

  • (String, nil)
    • A markdown summary suitable for display in a listing.


14
# File 'lib/custom_elements_manifest_parser/data_types/slot.rb', line 14

attribute :summary, Types::Strict::String.optional.meta(required: false)

Instance Method Details

#visit(parser:) ⇒ Object



26
27
28
# File 'lib/custom_elements_manifest_parser/data_types/slot.rb', line 26

def visit(parser:)
  self
end