Skip to content
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

JavaScript execution returned a result of an unsupported type #32

Open
dlpigpen opened this issue Dec 6, 2020 · 6 comments
Open

JavaScript execution returned a result of an unsupported type #32

dlpigpen opened this issue Dec 6, 2020 · 6 comments

Comments

@dlpigpen
Copy link

dlpigpen commented Dec 6, 2020

I got this error when loading flutter HTML editor.

[VERBOSE-2:ui_dart_state.cc(177)] Unhandled Exception: PlatformException(evaluateJavaScript_failed, Failed evaluating JavaScript, JavaScript string was: '$(".note-placeholder").html("Your text here...");'
Error Domain=WKErrorDomain Code=5 "JavaScript execution returned a result of an unsupported type" UserInfo={NSLocalizedDescription=JavaScript execution returned a result of an unsupported type}, null)
#0      StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:582:7)
#1      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:159:18)
<asynchronous suspension>
#2      MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:332:12)
#3      MethodChannelWebViewPlatform.evaluateJavascript (package:webview_flutter/src/webview_method_channel.dart:115:21)
#4      WebViewController.evaluateJavascript (package:webview_flutter/webview_flutter.dart:672:39)
#5      HtmlEditorState.setHint (package:html_editor/html_editor.dart:25<…>
[VERBOSE-2:ui_dart_state.cc(177)] Unhandled Exception: PlatformException(evaluateJavaScript_failed, Failed evaluating JavaScript, JavaScript string was: '$(".note-placeholder").html("Your text here...");'
Error Domain=WKErrorDomain Code=5 "JavaScript execution returned a result of an unsupported type" UserInfo={NSLocalizedDescription=JavaScript execution returned a result of an unsupported type}, null)
#0      StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:582:7)
#1      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:159:18)
<asynchronous suspension>
#2      MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:332:12)
#3      MethodChannelWebViewPlatform.evaluateJavascript (package:webview_flutter/src/webview_method_channel.dart:115:21)
#4      WebViewController.evaluateJavascript (package:webview_flutter/webview_flutter.dart:672:39)
#5      HtmlEditorState.setHint (package:html_editor/html_editor.dart:25<…>

@teknofreek
Copy link

i have the same error.

@AndrewPiterov
Copy link

+1 with
html_editor: ^1.0.1

@M1123581E
Copy link

same error

@Husniddin-dev
Copy link

Same

1 similar comment
@miguelpruivo
Copy link

Same

@tneotia
Copy link

tneotia commented Feb 20, 2021

I forked this library and have made some pretty massive changes to it, you can find it here. I've fixed this issue (and many others) in that library.

I would have preferred to create PRs but it seems this library is lacking maintenance so I took it upon myself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants