mimekit-ts - v1.0.0
    Preparing search index...

    Class HtmlAttributeCollection

    A readonly collection of HTML attributes.

    Implements

    Index

    An empty attribute collection.

    • Check if an attribute exists by id or name.

      Parameters

      • idOrName: string

        The attribute identifier or name.

      Returns boolean

      true if the attribute exists within the collection; otherwise, false.

      idOrName is null or undefined when treated as a name.

    • Get the index of a desired attribute by id or name.

      Parameters

      • idOrName: string

        The attribute identifier or name.

      Returns number

      The attribute index, or -1 if the attribute is not found.

      idOrName is null or undefined when treated as a name.

    • Get an attribute from the collection if it exists.

      Parameters

      • idOrName: string

        The attribute identifier or name.

      Returns HtmlAttribute | null

      The attribute if found; otherwise, null.

      idOrName is null or undefined when treated as a name.