build method

  1. @override
Widget build()
override

Subclasses should override this function to actually call the appropriate build function (e.g., StatelessWidget.build or State.build) for their widget.

Implementation

@override
Widget build() {
  try {
    container = HypenScope.of(this);
    if (isFirstBuild) {
      final w = state as HypenWidgetState;
      for (final action in w.effects) {
        action.hypen = this;
        action.register();
        if (action is HypenWidgetEffect) {
          action.initWidget();
        }
      }
      isFirstBuild = false;
    }
    return super.build();
  } on AccessWhileLoadingError catch (e, s) {
    return (state as HypenWidgetState).buildLoader(this);
  } catch (e, s) {
    rethrow;
  }
}