Questions tagged [flutter-js]
12 questions
4
votes
2 answers
Import js.dart and html.dart for a mixed web / mobile flutter project
I'm using Flutter 2.5.2. I have a project which is to be used for both web and mobile (Android / iOS).
There is one particular widget where I need to use one version of the widget when deploying for web, which uses the JS and HTML packages. When…

James Allen
- 6,406
- 8
- 50
- 83
1
vote
1 answer
Is it possible to use JS visual libraries (e.g. Chart.js or D3.js) in Flutter?
If it is possible, how exactly does it work? Maybe it's possible to access Flutter's Canvas widget through JS?
My best guess for this would be the flutter_js package.

Philippe Fanaro
- 6,148
- 6
- 38
- 76
1
vote
1 answer
TypeError: this._didCreateEngineInitializerResolve is not a function
I updated Flutter SDK yesterday and since then my web app doesn't run. I just see a white screen and in the console/log I see this error:
Do not call didCreateEngineInitializer by hand. Start with loadEntrypoint instead.
Uncaught (in promise)…

Danish Ajaib
- 83
- 1
- 3
- 14
1
vote
1 answer
Mock JS object in tests on browser platform
I have this simplified dart file using dart:js:
(dataLayer is used for Google tags, if that's any help)
@JS()
import 'package:js/js.dart';
@JS('dataLayer.push')
external void _push(data);
class Manager {
void pushEvent(String event) {
…

Valentin Vignal
- 6,151
- 2
- 33
- 73
0
votes
0 answers
how to use javascript channel in flutter web webview?
controller = WebViewController()
..setJavaScriptMode(JavaScriptMode.unrestricted)
..setBackgroundColor(Color.fromARGB(255, 255, 255, 255))
..addJavaScriptChannel('app', onMessageReceived: (s) {
if (s.message == "close")…
0
votes
0 answers
How to resolve the error : No signature of method: build_3ov23u7xor54ble5ncs4vfgan.android() is applicable for argument
Hello everyone I'm asking for help here because after a week of searching and trying I still can't solve an error, preventing me from recompiling my flutter application into an android version.
Here are the facts: After installing the flutter_js…

Simeon Simeonov
- 1
- 1
0
votes
1 answer
How to add channel to send message in flutter_js
I am trying to pass a message from Javascript to Flutter using package flutter_js but it seems like it's not working cuz it shows No Channel " " registered
below is my code
Future getObjectName(JavascriptRuntime jsRuntime) async {
final…

jl.bat
- 1
0
votes
0 answers
How can I show image in flutter by file without path?
I want to show the image in flutter, but I have a file just in two shapes (file - base64).

Ammar Kayali
- 5
- 5
0
votes
0 answers
Flutter: Is there any way to show custom widgets inside WebView?
I need all the functionalities (e.g., Searching) that a WebView provides on a WebPage but don't want to show any WebPage (provided to the initialUrl property) in the UI.
Instead, I need to show Custom Widgets inside the WebView widget upon which I…

Aurangzeb Hossain
- 51
- 1
- 4
0
votes
0 answers
I am viewing YouTube in webview and want to remove the bottom menu
I want to erase the part indicated by the arrow on the screenshot.
However, I could not get the tag for the smart phone version and could not erase it.
So I need to know how to turn it off.
import 'dart:async';
import 'dart:io';
import…

Tdayo
- 269
- 4
- 11
0
votes
0 answers
How to pass message from Flutter web app to Native Android/iOS app when the Webapp is Loaded in the Webview
I have built a Web app completely on Flutter and a few pages of this Webapp will be rendered in the Existing Native iOS and Android App through respective Webviews.
In this architecture, the Use case is, There's a button inside the Webapp when…

Vishak A Kamath
- 117
- 14
0
votes
1 answer
Flutter js unit test
I have a flutter test project which depends on futter js (javascript environment) this, I wrote a unit test to it. But I keep getting error on this line
jsRuntime = getJavascriptRuntime();
Invalid argument(s): Failed to load dynamic library…

Jimmy
- 27
- 3