MCPcopy Create free account
hub / github.com/arcjet/gravity / embed

Function embed

cmd/gravity/src/go/embed.rs:24–29  ·  view source on GitHub ↗

Helper function to create an embed directive.

(path: T)

Source from the content-addressed store, hash-verified

22
23/// Helper function to create an embed directive.
24pub fn embed<T>(path: T) -> Embed<T>
25where
26 T: Into<ItemStr>,
27{
28 Embed(path)
29}
30
31#[cfg(test)]
32mod tests {

Callers 1

test_embed_directiveFunction · 0.85

Calls 1

EmbedClass · 0.85

Tested by 1

test_embed_directiveFunction · 0.68