# options.OptionValue.decode

- **Module:** options.OptionValue
- **Package:** libtmux
- **Language:** Rust
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-rs/blob/8a648c0894dfffc9303583f753b6c8ae01f2fe76/crates/libtmux/src/options.rs#L257
- **Page:** https://libtmux.org/reference/rs/options-optionvalue-decode/

```
options.OptionValue.decode(name: &str, value: TmuxText) -> Self
```

Decode a stored value according to an option's declared kind.

A value that does not match its declared kind stays [`OptionValue::Text`]
rather than being discarded, because tmux stored it and the caller may
still want it.
