updateState method
Updates the shared state for a specific type.
Parameters:
type: The identifier for the state type to updatestate: A map containing the new state data. Can be null to clear the state.
The state is stored on the native platform and can be retrieved later using getState or getAllState.
Implementation
@override
Future<void> updateState(String type, Map<String, dynamic>? state) async {
await methodChannel.invokeMethod('updateState', {
'type': type,
'state': state,
});
}