TF-2460 Use conditional export for BroadcastChannel to avoid failed compilation

This commit is contained in:
dab246
2024-03-25 09:36:13 +07:00
committed by Dat H. Pham
parent 971b228107
commit f5e6cd0822
5 changed files with 18 additions and 3 deletions
@@ -0,0 +1 @@
export 'broadcast_channel_stub.dart' if (dart.library.html) 'broadcast_channel_web.dart';
@@ -0,0 +1,7 @@
class BroadcastChannel {
final String name;
BroadcastChannel(this.name);
Stream<dynamic> get onMessage => const Stream.empty();
}
@@ -0,0 +1 @@
export 'dart:html' show BroadcastChannel;