---
title: The component folder
project: UI Builder
version: 1.0
section: development
language: en
license: MIT
url: https://totaljs.es/docs/uibuilder/1-0/development/component-folder/
updated: 2026-11-19T11:56:06.259Z
---

# The component folder

> The files of a component, the parts of each file and how UI Builder finds them.

A component lives in a folder named after its id, for example `greeting/`. UI Builder only needs the address of `editor.html`; it finds the other files next to it.

```text
greeting/
	editor.html      the look in the editor, the details and the readme
	render.html      the code of the published design
	settings.html    the settings form
```

## editor.html

`editor.html` is the file you import. It can hold these parts:

| Part | What it holds |
|---|---|
| `<style>` | CSS for the component. |
| `<script>` | The declaration: `exports.id`, `exports.name`, `exports.make` and the other properties. |
| `<body>` | An HTML template that the code can use as `instance.component.html`. |
| `<readme>` | The text of **Read information** and **Read me**, in Markdown. |
| `<settings>` | The settings form, when you do not use `settings.html`. |

Write the tags exactly as `<script>` and `<style>`, without attributes. UI Builder looks for these exact tags. A file without `<script>` is read as JavaScript only.

## render.html

`render.html` runs in the published design. It needs `exports.id`, `exports.make` and, if the component has them, `exports.inputs` and `exports.outputs`. It does not need a name, a group, a readme or settings: UI Builder removes the readme and the settings from the published design.

`exports.render = 'auto'` in `editor.html` tells UI Builder to use the `render.html` next to it. You can also give a full address. Without `exports.render`, the published design uses the code of `editor.html`.

## settings.html

`settings.html` holds only the fields of the settings form. `exports.settings = 'auto'` in `editor.html` tells UI Builder to load it. `exports.settings` can also hold the form as an HTML string or an address of another file. See [Settings and the settings form](../settings-form/).

## The word CLASS

In the CSS, the HTML and the code, UI Builder replaces the word `CLASS` with a class name of its own for the component, for example `ui_14x7x60_3eax4p`. The element of every instance has that class. Write `.CLASS` in your CSS and the styles apply only to your component. See [Styles and libraries](../styles-and-assets/).

## A component without files

**Create** in the editor makes a component inside the design, with all parts in one source. See [Create a component](/uibuilder/1-0/guides/create-component/). A folder is better for a component you share: you can keep the editor and the published code apart, and change the files without opening each design.
