# config.Workspace.from_yaml_strict

- **Module:** config
- **Package:** tmux-workspace
- **Language:** Rust
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-rs/blob/a6fc2a65674177b92b17fa380757155d2ba150fd/crates/tmux-workspace/src/config/parse.rs#L85
- **Page:** https://libtmux.org/en/rs/latest/workspace/reference/config-workspace-from_yaml_strict/

This type appears in public signatures. It is not a package entry point.

```
config.Workspace.from_yaml_strict(source: &str) -> Result<Self, ConfigError>
```

Parse as [`Self::from_yaml`] does, refusing a key that is neither this parser's own vocabulary nor tmuxp's, unless it starts with `x-`.

This is the policy the `tmux-workspace` command applies to every
document it loads.

# Errors

What [`Self::from_yaml`] returns, and also an unrecognized key.

## Examples

```rust
use tmux_workspace::Workspace;

let error = Workspace::from_yaml_strict("session_name: demo\nwindows: []\nfrobnicate: 1\n")
    .expect_err("an unrecognized key is refused");
assert!(error.to_string().contains("frobnicate"));
```
