Created
December 11, 2014 21:41
-
-
Save ef4/1f14ba48a9999379b89a to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| export default Ember.Component.extend({ | |
| didInsertElement: function() { | |
| this.canvas = new fabric.Canvas(this.get('element')); | |
| this.drawSomeStuffUsingCanvas(); | |
| }, | |
| updateSomething: Ember.observer('someField', function(){ | |
| // Change canvas to reflect 'this.someField' | |
| }) | |
| }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This would go into "app/components/fabric-canvas.js".
Then you would use in a template like: