Documentation menu

TypePlaceholder

A placeholder for a Type node that does not exist. Can be populated using the `edit` method.

View source on GitHub

Inherits from

Placeholder

Methods


edit

Edits the type annotation of a placeholder node.

View source on GitHub

Parameters

new_srcrequired

The new type annotation text to be inserted.

fix_indentationdefault: False

Whether to fix the indentation of the new source.

prioritydefault: 0

Priority of the edit operation.

dedupedefault: True

Whether to remove duplicate edits.

Returns

remove

Removes this element from its parent container.

View source on GitHub

Returns