Retrieves all descendant of a given view model type with an optional filter.

public static async ValueTask<IReadOnlyList<INodeViewModel<TModel>>> DescendantsAsync<TModel>(IRedaktContext context, string nodeId, Func<dynamic, bool> filter, Nullable<CultureInfo> forCulture)
Returns:
ValueTask<IReadOnlyList<INodeViewModel<TModel>>>

Parameters

nodeId string

The node id to get the descendants for.

filter Func<dynamic, bool>

An optional filter predicate.

forCulture Nullable<CultureInfo>

Type Parameters

TModel

The view model type of the descendants.

In this article