# Dynamic mode

The application enables the loader before constructing its interface:

```cpp
aura::ui::Loader::global().enableFromEnvironment(); // AURA_DIR
```

Use `AURA_DIR` to select source files. Without a value, the application uses its compiled UI:

```bash
AURA_DIR=$PWD/ui ./my-app
AURA_DIR= ./my-app
```

- **Loading:** before every construction, the loader checks the modification times of all `*.aura` files in the directory and its subdirectories and reloads all files when anything changes. A change becomes visible the next time the dialog opens.
- **Identical behavior:** the interpreter (`libs/aura-ui/src/builder/`) follows the generator's rules step by step: property order, deferred properties, `pressed` groups, bindings, and rebuilding with anchors and guards.
- **Errors:** if the dialog is missing from the directory or a file contains an error, a warning is written to the log (`W [aura]`) and the compiled version appears. Partially constructed nodes are removed first. Because this happens without interrupting the application, watch the log while developing.
- **Versions:** if the file and compiled application do not match (for example, a new argument), the loader reports “no value for the argument” and uses the compiled version.
- **Availability:** development builds only.
- **Enabling:** `aura::ui::Loader::global().enableFromEnvironment("AURA_DIR")` (default name `AURA_DIR`): takes the directory from the environment and writes errors and notices to the log.
- **Without the application:** `tools/aura-view` displays dialogs and screens independently of the application's flow, including live updates while typing in VS Code ([aura-view.md](aura-view.md)). It supplies placeholders for dialog arguments (`"test-<name>"`, `0`, `false`; record lists with one entry).
