Skip to content

parseWorkspaceLayoutStateRecord

Parses a persisted record. A part that is malformed is dropped one level at a time: a malformed record reads as empty, a malformed plugin record drops only that plugin, and a malformed leaf bucket drops only that leaf. Fields this copy does not know are kept.

Import:

import { parseWorkspaceLayoutStateRecord } from '@mnaoumov/obsidian-lib/components/workspace-layout-state-component';

Signature:

function parseWorkspaceLayoutStateRecord(value: unknown): WorkspaceLayoutStateRecord

Parameters:

Parameter Type Description
value unknown The value found under WORKSPACE_LAYOUT_STATE_LAYOUT_KEY.

Returns: WorkspaceLayoutStateRecord — The parsed record, sharing nothing with the input.