Edit in GitHubLog an issue

window.HTMLSlotElement

See: Web APIs - HTMLSlotElement
Since: v7.0.0

name : string

A string used to get and set slot's name.

See: HTMLSlotElement - name

assignedNodes(options)

returns a sequence of the nodes assigned to this slot. If options object is used with flatten: "true", If slottables is the empty list, then append each slottable child of slot, in tree order, to slottables.
Refer find-flattened-slotables

Returns: Array - An array of nodes
See: HTMLSlotElement - assignedNodes

ParamTypeDescription
options
Object
An object that sets options for the nodes to be returned

Properties

NameTypeDescription
options.flatten
boolean
A boolean value indicating whether to return the assigned nodes of any available child slot elements (true) or not (false). Defaults to false.

assignedElements(options)

returns a sequence of the elements assigned to this slot. If options object is used with flatten: "true", If slottables is the empty list, then append each slottable child of slot, in tree order, to slottables.
Refer find-flattened-slotables

Returns: Array - An array of elements
See: HTMLSlotElement - assignedElements

ParamTypeDescription
options
Object
An object that sets options for the elements to be returned

Properties

NameTypeDescription
options.flatten
boolean
A boolean value indicating whether to return the assigned elements of any available child <slot> elements (true) or not (false). Defaults to false
Was this helpful?
  • Privacy
  • Terms of Use
  • Do not sell or share my personal information
  • AdChoices
Copyright © 2024 Adobe. All rights reserved.