# Basic example

**I assume that you have read the installation section and that you have initialized and configured Startox.**

### Create component view

Create a template file named "ingress.js" and add the code below.

```javascript
export default function ingressComponent({ props })
{
    return `
    <header class="mb-50 align-center">
        <h1>${props.headline}</h1>
        <p>${props.content}</p>
    </header>
    `;
}
```

### Show component view

I will break down and explain the example in the next page.

```javascript
import ingressComponent from './path/to/ingress.js';

const stratox = new Stratox("#app");

stratox.view(ingressComponent, {
  headline: "Lorem ipsum dolor",
  content: "Lorem ipsum dolor sit amet"
});

stratox.execute();
```

### The result

{% embed url="<https://codepen.io/wazabii8/pen/bGZgPNo>" %}

Let's move on to the next section, where I will go in-depth on how it really works.


---

# 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://stratox.wazabii.se/stratox.js/template-engine/basic-example.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.
