feat(build): emit checked component refs
Generate ComponentRef constants for component-scoped APIs, include global component refs only when global_exports(true) is enabled, and document/use the checked component token. req: component/003
This commit is contained in:
+2
-2
@@ -166,8 +166,8 @@ slhx competes with React by making frontend frameworks unnecessary for most apps
|
||||
|
||||
### req: component/003
|
||||
003 Generated APIs are component-namespaced by default:
|
||||
`ui::slots::todo_row`, `ui::handles::create`, `ui::forms::create`.
|
||||
Global exports are opt-in only.
|
||||
`ui::todo_list::slots::todo_row`, `ui::todo_list::handles::create`, `ui::todo_list::forms::create`, and `ui::todo_list::COMPONENT` as a checked `ComponentRef`.
|
||||
Global exports (`ui::slots::*`, `ui::handles::*`, `ui::components::*`) are opt-in only.
|
||||
|
||||
### req: component/004
|
||||
004 `#[slhx::surface]` bridges generated code into a user module. Users write `#[slhx::surface] mod ui {}` instead of `include!(concat!(env!("OUT_DIR"), ...))`. slhx-build emits `slhx.generated.rs` which the macro expands in place. No direct `$OUT_DIR` includes in user-authored source.
|
||||
|
||||
Reference in New Issue
Block a user