Closed aidandavis closed 4 years ago
I'm not a flutter user but I'm sure flutter is a server side Dart implementation, hence it can't find dart:html in which case you will need mqtt_server_client.dart not mqtt_browser_client.dart. The mqtt_browser_client.dart is intended for use in browsers, not the Dart VM
Thanks for your fast response! It's working for me now. I think this advice should be added to the readme.
For Flutter, use mqtt_server_client.dart
rather than mqtt_browser_client.dart
.
Hi, I am trying to install this plugin for my flutter app, but simply having
import 'package:mqtt_client/mqtt_browser_client.dart';
at the top of a class causes the following error and the app doesn't build.Any suggestions? Looking back through the closed issues this one pops up, #144 . Doesn't have a fix for it. I am Flutter (Channel stable, v1.17.0, on Microsoft Windows [Version 10.0.18362.778], locale en-AU), and mqtt_client: ^7.1.0