Last active
December 19, 2015 18:29
-
-
Save d2m/5998923 to your computer and use it in GitHub Desktop.
polymer.dart : passing values into a component does not work
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>attributes</title> | |
</head> | |
<body> | |
<element name="x-attributes" attributes="model"> | |
<template> | |
model: {{ model }} | |
</template> | |
<script type="application/dart"> | |
import 'package:polymer/polymer.dart'; | |
import 'package:observe/observe.dart'; | |
class XAttributes extends CustomElement with ObservableMixin { | |
@observable var model = 'abc'; | |
} | |
</script> | |
</element> | |
<x-attributes model="123"></x-attributes> | |
<script type="application/dart"> | |
import 'package:mdv/mdv.dart' as mdv; | |
void main() { | |
mdv.initialize(); | |
} | |
</script> | |
<script src="packages/browser/dart.js"></script> | |
</body> | |
</html> | |
======================== output ====================== | |
model: abc | |
======================== expected ==================== | |
model: 123 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment