notifyTitleChanged method

void notifyTitleChanged(
  1. InAppWebViewController controller,
  2. String? title
)

Implementation

void notifyTitleChanged(InAppWebViewController controller, String? title) {
  state = state.copyWith(
    controller: WebViewStateProp(controller),
    // Avoid updating the title if it's the same as the current url
    title: title != state.url.toString() ? WebViewStateProp(title) : null,
  );
}