postMessage method

Sends a postMessage request using the origin communicated via requestPostMessageChannel. Fails when called before PlatformChromeSafariBrowserEvents.onMessageChannelReady event.

message – The message that is being sent.

Returns an integer constant about the postMessage request result. Will return CustomTabsService.RESULT_SUCCESS if successful.

Officially Supported Platforms/Implementations:

Implementation

Future<CustomTabsPostMessageResultType> postMessage(String message) {
  throw UnimplementedError(
      'postMessage is not implemented on the current platform');
}