receiveFromFrontend method
Implementation
@override
void receiveFromFrontend(int? id, String method, Map<String, dynamic>? params) async {
switch (method) {
case 'getResourceContent':
String? url = params!['url'];
sendToFrontend(id,
JSONEncodableMap({'content': devtoolsService.controller?.getResourceContent(url), 'base64Encoded': false}));
break;
case 'reload':
sendToFrontend(id, null);
handleReloadPage();
break;
default:
sendToFrontend(id, null);
}
}