Skip to main content
7 votes
5 answers
14k views

Flutter web debug is working but build web shows a blank page

flutter doctor result [√] Flutter (Channel dev, 1.21.0-1.0.pre, on Microsoft Windows [Version 10.0.19041.388], locale en-US) [√] Android toolchain - develop for Android devices (Android SDK version 29....
sidrao2006's user avatar
  • 1,328
3 votes
0 answers
751 views

Is there a way to turn off tree shaking when I build a flutter for web app with the "Flutter build web" command?

I am trying to put a prototype of my flutter app on the web so I can show it to some people but in release mode some features are broken while in debug mode they are not. I want to turn off tree-...
lost baby's user avatar
  • 3,268
0 votes
1 answer
109 views

Dart Webdev Dev Compiler not running since upgrade to 2.3.2

Since I have moved from Dart 2.1.0 to 2.3.2 "webdev serve" runs successfully, but when I run the project, it gets a 404 on "main.digests". I updated my dev dependencies of build_runner, ...
AndrewL's user avatar
  • 329
1 vote
1 answer
492 views

SASS not compiling with the Dart DDC

I am getting the following errors when compiling my web-app with DDC: SEVERE] build_web_compilers|ddc on package:sass/sass.dartdevc.module (cached): Error compiling dartdevc module:sass|lib/sass.ddc....
Asperger's user avatar
  • 3,262
4 votes
1 answer
2k views

Using Dart JS interop with ES6 classes

JavaSscript: class MyClass { constructor() { console.log("MyClass instance created"); this.answer = 42; } } let example = new MyClass(); console.log(example.answer); Dart: @...
András Szepesházi's user avatar
1 vote
0 answers
94 views

Mouse event for download working with dartdevc, but not dart2js

I am trying to use code modeled after https://stackoverflow.com/a/29702251/9885144 to do an HttpRequest, generate a download link from the returned blob, then automatically download it (all after ...
David Griswold's user avatar
3 votes
0 answers
158 views

Unable to find module for angular - bootstrap/modules.template.dart

I have a problem with transpiling Angular Dart application to javascript. I got following error messages: *Loading source assets... Loading dart_to_js_script_rewriter transformers... Building ...
Jakub's user avatar
  • 31
1 vote
0 answers
292 views

How to cast HtmlWebSocketChannel to StreamChannel<String> under strong mode?

I'm trying to connect to a json_rpc server in Chrome 62 on DDC 1.24.2 using the standard json_rpc_2 pub package. I'm following the Client based example found at: https://github.com/dart-lang/...
Joshua Ferguson's user avatar
0 votes
1 answer
167 views

Is it possible to call Dart code generated with dartdevc from JavaScript?

I have a bunch of Dart libraries that a customer wants to call from JavaScript. Is it possible to call functions created with dartdevc from JS?
jfp's user avatar
  • 431
0 votes
1 answer
291 views

Compiling Dart into minifier friendly javascript: From dartdevc into google-closure-compiler

What compiler options are best to ensure that dartdevc generates minifier friendly javascript code which can be compressed by google closure compiler in ADVANCED mode. Please show a tested example ...
Malelago's user avatar
1 vote
1 answer
200 views

same pubspec.yaml - build for both ddc and dart2js with debug

In current state of project I want to build both for ddc and dart2js with debug info. Is this possible with same pubspec.yaml? Using the recommended setting for ddc, the debug mode is associated ...
Jonas Bojesen's user avatar
0 votes
1 answer
67 views

How can I call a Dart library created with DDC from JavaScript?

I've created a large library in Dart that need to be called from JavaScript. I'd like to avoid using JS Interop if possible. Can I use the Dart Dev Compiler to do this? Is it possible to take the ...
jfp's user avatar
  • 431
1 vote
1 answer
57 views

Is Dart Dev Compiler supposed to support dart:io?

I tried compiling a simple HttpServer.bind with DDC and it seems to throw a runtime error saying "Operation not supported" on that line. Am I doing something wrong, or is DDC not supposed to support ...
Pacane's user avatar
  • 21.6k
1 vote
2 answers
438 views

How can I interop with existing JS objects?

I'm trying to write Dart code that will generate a rough equivalent of this: var disposable = vscode['commands'].registerCommand( 'extension.sayHello', function () { vscode['window']....
Danny Tuppeny's user avatar