Fit a frame to its content.

function fitFrameToContent(
  editor: Editor,
  id: TLShapeId,
  opts?: {
    padding: number
  }
): void
Parameters
NameDescription

editor

Editor

tlraw editor instance.

id

TLShapeId

Id of the frame you wish to fit to content.

opts

{
  padding: number
}

Options for fitting the frame.

Returns
void
exportToBlobgetArrowBindings