add template_value to prelude (#23669)

# Objective

`template_value` is not in the prelude, but seems useful enough to be.
It seems like the main way to include an existing component value in a
`bsn!` declaration since using `{transform}` and similar expressions
doesn't work.

```rust
// some Transform, maybe from an `In<Transform>` or other argument.
let transform = Transform::from_xyz(5., 0., 5.);

bsn! {
    #SomeThing
    template_value(transform)
}
```

## Solution

Add `template_value` to the prelude.
This commit is contained in:
Chris Biscardi
2026-04-06 12:33:52 -07:00
committed by GitHub
parent fcabe2a01b
commit fed46a1986
+3 -2
View File
@@ -506,8 +506,9 @@
/// This includes the most common types in this crate, re-exported for your convenience.
pub mod prelude {
pub use crate::{
bsn, bsn_list, on, CommandsSceneExt, EntityCommandsSceneExt, EntityWorldMutSceneExt,
PatchFromTemplate, PatchTemplate, Scene, SceneList, ScenePatchInstance, WorldSceneExt,
bsn, bsn_list, on, template_value, CommandsSceneExt, EntityCommandsSceneExt,
EntityWorldMutSceneExt, PatchFromTemplate, PatchTemplate, Scene, SceneList,
ScenePatchInstance, WorldSceneExt,
};
}