Skip to main content

set_storage

Function set_storage 

Source
pub fn set_storage(key: &str, value: &str)
Expand description

Set a storage value scoped to this app.

Storage is persisted by the host across app restarts and is isolated per-app: other apps cannot read or write keys you set here. Useful for small bits of configuration or state; for larger or relational data, prefer the core.storage.* capabilities.

No-op when the host context is not available or key/value contain interior NUL bytes.