Closed LSMetag closed 9 years ago
Your transformer config is invalid. Here is a working example http://stackoverflow.com/questions/32242736/import-and-make-use-of-polymer-dart-0-17-dev-preview You need to configure the entry_point once for web_components and once for the reflectable transformer while the former expects the path to the html file and the later to the dart file.
Thank you !
It works now ! Just a question : is it because you use "reflectable" that "@observable" is regarded as an error ? (Not a compile-time constant. @observable)
name: CVWebkit description: An online jobboard for employers and contestants dependencies: dart_config: any browser_detect: any sass : any polymer: git: url: https://github.com/dart-lang/polymer-dart.git ref: 1.0.0-rc.2 web_components: ^0.12.0 polymer_elements: git: https://github.com/dart-lang/polymer_elements.git
dependency_overrides: polymer_interop: git: ref: 0.2.0-rc1 url: https://github.com/dart-lang/polymer_interop.git reflectable: 0.3.0
transformers:
observable isn't necessary or supported anymore. In Polymer 1.0 you have to explicitely notify Polymer about about changes with methods your element inherits from the PolymerElement class like set()
, add()
, remove()
, and notifyPath()
...
You can find more details about how to work with Polymer 1.0 at https://github.com/dart-lang/polymer-dart/wiki#10-developer-guide.
There is some work in progress to allow to work with observable like in the previous Polymer version, but I don't know about the status. See #570
Thank you !
Attributes are not supported.
Here is a part of the new way : https://www.polymer-project.org/1.0/docs/devguide/properties.html
Glad to hear you got it working. Polymer 1.0 is exciting and working quite well already also the Polymer elements. At https://github.com/bwu-dart-contributing/polymer_elements/tree/demo2/demo you can find examples about how to use the elements in Dart Polymer 1.0 I added notes in the pubspec.yaml where I run into problems.
Not sure what you mean by
Attributes are not supported.
If your issue is resolved, please close this issue. Thanks :)
If you want support for osservable in polymer 1.0 you can try
https://github.com/dam0vm3nt/polymer_autonotify
Il giorno dom 4 ott 2015 17:25 LSMetag notifications@github.com ha scritto:
Closed #613 https://github.com/dart-lang/polymer-dart/issues/613.
— Reply to this email directly or view it on GitHub https://github.com/dart-lang/polymer-dart/issues/613#event-426227553.
I recently migrated from Polymer 0.16+3 to 1.0.0-rc.2 in my Dart project. I am using Dart 1.13.0-dev.5.0.
When I try to build the project I get these errors in various polymer, polymer_interop and webcomponent files.
"The built-in library 'dart:html' is not available on the stand-alone VM.' "The built-in library 'dart:js' is not available on the stand-alone VM."
It seems to compile when I remove these references.
Here is my pubspec.yaml file :
name: CVWebkit description: An online jobboard for employers and contestants dependencies: dart_config: any browser_detect: any sass : any polymer: git: url: https://github.com/dart-lang/polymer-dart.git ref: 1.0.0-rc.2 reflectable: 0.2.1 web_components: ^0.12.0
dependency_overrides: polymer_interop: git: ref: 0.2.0-rc1 url: https://github.com/dart-lang/polymer_interop.git reflectable: 0.2.1
transformers: