Rush StackShopBlogEvents
Skip to main content

Home > @rushstack/lookup-by-path > LookupByPath > deleteSubtree

LookupByPath.deleteSubtree() method

This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Deletes an item and all its children.

Signature:

deleteSubtree(query: string, delimeter?: string): boolean;

Parameters

Parameter

Type

Description

query

string

The path to the item to delete

delimeter

string

(Optional) Optional override delimeter for parsing the query

Returns:

boolean

true if any nodes were deleted, false otherwise