# Create Element Block

This block creates an element and inserts it into the webpage.

* **Element selector**\
  The element selector of the specific element.
* **Insert element**\
  Represent the position of the specific element.
  * **As first child**\
    Insert it as the first child of the specific element.
  * **As last child**\
    Insert it as the last child of the specific element.
  * **As previous sibling**\
    Insert it as the previous sibling of the specific element.
  * **As next sibling**\
    Insert it as the next sibling of the specific element.
  * **Replace target element**\
    Substitue the specific element for the element that was created.
* **HTML**\
  The HTML code of the element you would like to create.
* **CSS**\
  The CSS code that will be injected into the webpage
* **JavaScript**\
  The JS that will be injected into the webpage
  * <mark style="color:red;">**`golessRefData(keyword, path?)`**</mark><mark style="color:red;">\*\* \*\*</mark><mark style="color:red;">**function**</mark>\
    Use this function for referencing data.\
    For further information, open the Javascript Block page.
  * <mark style="color:red;">**`golessExecWorkflow(detail)`**</mark><mark style="color:red;">\*\* \*\*</mark><mark style="color:red;">**function**</mark>\
    Workflow execution functionality.\
    The `detail` parameter is where you input the detail of the workflow like the ID or `publicId` of the workflow you want to run.
* **Preload script**\
  Load scripts or styles before injecting the element.

Please note:

This block cannot function without an active tab. For this reason, use the Active Tab block or the New Tab block before using this one.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.goless.com/blocks/web-interaction/create-element-block.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
