initInternalChannelsForWeb method
Initializing the internal channels for internal message exchange
Implementation
void initInternalChannelsForWeb(BuildContext context) async{
_internalChannels = [
// Registering the channel for popping screens
NUIMiniProgramChannel(NUIMiniProgramWebEventType.CAN_POP.value, listener: (data, message) async{
final canPop = Navigator.canPop(context);
if(canPop){
pop(context);
}
final reply = NUIMiniProgramMessage(id: message.id, data: canPop ? "true": "false", channel: NUIMiniProgramWebEventType.CAN_POP.value);
return reply;
}),
];
}