Instance accessors

Public

Tag.prototype.attributes

The getarrow-up-right accessor returns the tag attributes if set, otherwise undefined.

public get attributes(): Attributes | undefined {
  return this.#attributes;
}

Returns

The return value is a tag attributes of an Attributes if set, or undefined.

Example usage

// Example usage.
import { Tag } from '@angular-package/text';

// Create tag [quote].
const tag = new Tag(`quote`, `<`, `>`, ['color', 'red']);

// Returns

Tag.prototype.closingTag

The getarrow-up-right accessor gets the closing tag of a generic type ClosingTag.

Returns

The return value is a tag closing of a generic type ClosingTag.

Example usage

Tag.prototype.name

The getarrow-up-right accessor gets the tag name without the wrap from the private property #name.

Returns

The return value is a tag name of a generic type variables Name.

Example usage

Tag.prototype.openingTag

The getarrow-up-right accessor gets the opening tag with optional attributes.

Returns

The return value is an opening tag of a generic type OpeningTag.

Example usage

Tag.prototype.tag

The getarrow-up-right accessor gets the tag consists of the name, opening and closing of the wrap.

Returns

The return value is a tag of a generic type variables in order Opening, Name and Closing on the template.

Example usage

Tag.prototype.wrapper

The getarrow-up-right accessor gets the wrapper.

Returns

The return value is the Wrapper instance.

Example usage

Tag.prototype.value

The getarrow-up-right accessor gets the tag without the attributes.

Returns

The return value is the tag of a generic type variables in order Opening, Name and Closing on the template.

Example usage

[Symbol.toStringTag]

The property, with the help of toStringTagarrow-up-right of Symbol, changes the default object tag to tag for an instance of the Tag.

circle-info

Good to know: The property can be read by the typeOf() function of the type package.

Example usage

Last updated