-
Notifications
You must be signed in to change notification settings - Fork 19
feat: Add support for WASM. #184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| http_parser: ^4.0.0 | ||
| uuid: ">= 3.0.7 <5.0.0" | ||
| crypto: ^3.0.3 | ||
| web: ^1.1.1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replaces dart:html
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file was regenerated.
| final messageEvent = event as web.MessageEvent; | ||
| final ldMessageEvent = ld_message_event.MessageEvent( | ||
| messageEvent.type, messageEvent.data, messageEvent.lastEventId); | ||
| messageEvent.type, (messageEvent.data as JSString).toDart, messageEvent.lastEventId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This cast should be done safer.
| final ldMessageEvent = ld_message_event.MessageEvent(messageEvent.type, | ||
| (messageEvent.data as JSString).toDart, messageEvent.lastEventId); | ||
| _messageEventsController.sink.add(ldMessageEvent); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kinyoklion This is my attempt to make this cast safer. ld_message_event.MessageEvent will not accept null for the data parameter so my thought is that if we can't cast it then we just skip handling the message. Thoughts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That sounds reasonable.
No description provided.