2

I've got the dart-sdk, updated my path to include the dart binaries, downloaded the tutorials and grabbed its dependencies by running "pub get". I'm going to lean toward using dart2js until dartium integrates fully with chromium, and using

dart2js clickme.dart -o clickme.dart.js

works fine from Firefox (I'm working in vim and not the Dart Editor or Spark).

But tutes using polymer don't include a main() so dart2js won't compile them. I'm not sure how to proceed. I don't know how to create an instance of TuteStopwatch, which extends PolymerElement, which might be used to create a main(), for example.

Günter Zöchbauer
  • 623,577
  • 216
  • 2,003
  • 1,567
rino
  • 491
  • 5
  • 12

1 Answers1

0

A more comfortable (IMHO) way to build is using 'pub build'.
For Polymer you need to configure a transformer in pubspec.yaml.

see How do I pass multiple entry_points to polymer transformer in pubspec.yaml?

Community
  • 1
  • 1
Günter Zöchbauer
  • 623,577
  • 216
  • 2,003
  • 1,567
  • Ok, but steps specific to the stopwatch tutorial would be more helpful. I noticed a dart-tutorials-samples-master/web/to-polymer-notes.txt but I couldn't get far with the instructions. – rino Mar 05 '14 at 06:34
  • The file you mention is about converting from PolymerDart predecessor WebUI to PolymerDart. When you are looking for an introduction to PolymerDart look here https://www.dartlang.org/polymer-dart/ – Günter Zöchbauer Mar 05 '14 at 07:30