For AI agents: the complete documentation index is available at /next/llms.txt, the full documentation bundle is available at /next/llms-full.txt, and this page is available as Markdown at /next/api/engine/element-api/__AppendElement.md.
Lynx
  • English
  • __AppendElement

    Introduction

    Inserts an Element object after the last child of the current Element.

    Syntax

    __AppendElement(parent: Element, child: Element) : Element;

    Parameters

    KeyDescription
    parentThe parent Element object.
    childThe child Element to be appended to the parent.

    Return Value

    Returns the appended child Element.

    Example

    The frontend framework can perform insertion operations as shown below.

    // main-thread.js
    let child = __CreateElement('view', 0, {});
    
    let parent = __CreateElement('view', 0, {});
    
    __AppendElement(parent, child);
    Except as otherwise noted, this work is licensed under a Creative Commons Attribution 4.0 International License, and code samples are licensed under the Apache License 2.0.