dart #import weirdness in dart editor dart #import weirdness in dart editor dart dart

dart #import weirdness in dart editor


You should only do the import once and then source your program files from your main file. Something like this:

main.dart

#import("dart:html");#source("program.dart");main() {   var program = new Program();   program.run();}

program.dart

class Program {   run() {       var elm = new Element.html("<p>hello world</p>");       document.body.nodes.add(elm);   }}

should definitely work.