JS builds for Polymer.dart work, but don't run

Showing 1-8 of 8 messages
JS builds for Polymer.dart work, but don't run montyr75 4/19/14 6:44 PM
I'm on the bleeding edge here, so there are bound to be problems, but I would like to know if others are having similar issues to mine.

Versions:
  Dart SDK version 1.4.0-dev.2.2
  polymer: 0.10.0-pre.9
  polymer_elements: 0.2.0-pre.5

Everything runs perfectly in Dartium, when run from the Editor.

None of my projects will run from a Pub Build, though, not even in Dartium. None of my projects will run as JS with this setup, either. Not with the Run as JavaScript command and not in Chrome after a Pub Build. Chrome comes up blank and the console shows this:

Resource interpreted as Script but transferred with MIME type application/vnd.dart: "http://localhost/example_project/build/web/index.html_bootstrap.dart"

Please tell me I'm not the only one seeing this, and that someone is even now fixing this up for Polymer's next stable release. Or even better, tell me I'm an idiot and I'm doing something wrong that can be easily fixed.
Re: JS builds for Polymer.dart work, but don't run montyr75 4/19/14 6:56 PM
Anyone who cares to check out the code for a whole project with this problem can do so here: https://github.com/montyr75/remember_me
Re: [dart-web] JS builds for Polymer.dart work, but don't run carljmosca 4/19/14 7:13 PM
I have not done a lot with dart lately but I did pull down your project (which looks nice in dartium BTW) and I encounter the same problem.

Carl


--
You received this message because you are subscribed to the Google Groups "Dart Web Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to web+uns...@dartlang.org.
Visit this group at http://groups.google.com/a/dartlang.org/group/web/.
To view this discussion on the web visit https://groups.google.com/a/dartlang.org/d/msgid/web/3d783887-3da0-417d-b359-66bcb22aebfb%40dartlang.org.



--
Carl J. Mosca
Re: [dart-web] JS builds for Polymer.dart work, but don't run James Hurford 4/19/14 8:59 PM
It doesn't work for me either, and I suspect, but am not sure, that it has something to do with this warning

platform.js is not the first script on the page. See http://www.polymer-project.org/docs/start/platform.html#setup for details.

James





--
James Hurford
terr...@gmail.com

There are two ways of constructing a software design: one way is to
make it so simple that there are obviously no deficiencies; the other is
to make it so complicated that there are no obvious deficiencies.
                                                       -- C.A.R. Hoare
Re: [dart-web] JS builds for Polymer.dart work, but don't run Günter Zöchbauer 4/21/14 9:22 AM
I think the error is because the script tag 'dart.js' (https://github.com/montyr75/remember_me/blob/master/web/index.html#L18) is redundant when 'packages/polymer/polymer.html' is imported.
I don't know if this prevents the app to run.
Re: [dart-web] JS builds for Polymer.dart work, but don't run John Messerly 4/21/14 11:39 AM
filed https://code.google.com/p/dart/issues/detail?id=18339 about the warning. It looks harmless though. Still investigating why the app isn't starting.
Re: [dart-web] JS builds for Polymer.dart work, but don't run John Messerly 4/21/14 12:41 PM
seems to be a bug in the deploy tool: https://code.google.com/p/dart/issues/detail?id=18340
however, it's probably a good idea to keep <link rel=import> outside of the <polymer-element> generally (unlike link rel=stylesheet). 

I also sent https://github.com/montyr75/remember_me/pull/1 with the workaround.

Thanks for catching this!
- John

Re: [dart-web] JS builds for Polymer.dart work, but don't run montyr75 4/21/14 4:27 PM
Whoa! Very nice! Thanks, John, for taking the time to look at this and getting me up and running again. I knew my faith in you guys was well placed.  :)

I run a local Dart meetup (http://www.meetup.com/Utah-Valley-Dartisans-Dart-Programming-Meetup/), and I'll be sure to emphasize to my members that the fantastic support from the Dart devs and the Dart community is another great reason to start using Dart.