Skip to main content
Version: 4.3

selectCellParent()

function selectCellParent(cell): ID | null;

Selects the id of the cell this one is embedded in, or null for a top-level cell. Works for elements and links alike, since any cell can be embedded.

Parameters

ParameterTypeDescription
cellComputed<CellRecord>the resolved cell record

Returns

ID | null

Example

import { useCell, selectCellParent } from '@joint/react';

const parentId = useCell(cellId, selectCellParent);

Stay in the know

Be where thousands of diagramming enthusiasts meet

Star us on GitHub