isWidgetCreationTracked method Null safety

bool isWidgetCreationTracked()

Returns whether Widget creation locations are available.

Requires Widget creation locations which are only available for debug mode builds when the --track-widget-creation flag is enabled on the call to the flutter tool. This flag is enabled by default in debug builds.

Implementation

bool isWidgetCreationTracked() {
  _widgetCreationTracked ??= _WidgetForTypeTests() is _HasCreationLocation;
  return _widgetCreationTracked!;
}