cleanup, docs
This commit is contained in:
@@ -45,12 +45,6 @@ That keeps file-based and hierarchical routing in normal UCE code instead of hid
|
||||
|
||||
The function library includes small collection helpers for common route/menu/card transformations:
|
||||
|
||||
```cpp
|
||||
auto visible = routes.filter([](String route) { return(route != "admin"); });
|
||||
auto labels = visible.map([](String route) { return(to_upper(route)); });
|
||||
DValue app_items = menu.filter([](DValue item, String key) { return(item["section"].to_string() == "app"); });
|
||||
DValue labels_by_key = menu.map([](DValue item, String key) { DValue out; out = item["label"].to_string(); return(out); });
|
||||
```
|
||||
|
||||
Use these when a short transformation is clearer than a loop. Prefer explicit loops for side effects or multi-step validation.
|
||||
|
||||
@@ -68,3 +62,6 @@ When a unit fails to compile, UCE reports the source path, generated C++ path, c
|
||||
- No global file-router is imposed by the runtime.
|
||||
- No JSX-like component tags are required for this workflow.
|
||||
- Component children/slot syntax is not part of UCE yet; use explicit props and component calls for now.
|
||||
|
||||
:example
|
||||
print("Coming from React documents a UCE concept.\n");
|
||||
|
||||
Reference in New Issue
Block a user