NativeScript 9.1 Released → V8 14.9, Vite 8 HMR, built for rapid agentic visual iteration
Dig in
ts
function getViewById(view: ViewBase, id: string): ViewBase;

Defined in: ui/core/view-base/index.ts

Gets a child view by id.

Parameters

ParameterTypeDescription
viewViewBaseThe parent (container) view of the view to look for.
idstringThe id of the view to look for. Returns an instance of a view (if found), otherwise undefined.

Returns

ViewBase