Take the 2-minute tour ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

I have problem with my code which is using 3rd party library. When I use it in the plain Dart itself it already works, but not with Angular.Dart. I have used chapter3 from Dart tutorial and just added my code in recipe_book.dart which is compoment.

Place where the code fails is shown in the picture below. After i get

Breaking on exception: object must be an Node, ArrayBuffer, Blob, ImageData, or IDBKeyRange

I don't have idea how to get rid of this:-( Maybe it is something somebody more familiar with Angulart.dart can answer right away.

Anybody willing to help can check the code here on github

enter image description here

share|improve this question
1  
Can you please try without the .fromBrowserObject, maybe even without new JsObject... like just event['target'] and add a comment about the outcome? –  Günter Zöchbauer Mar 1 at 12:16
    
Works, but why is that? It was working in plain Dart. I use it according to your advice here stackoverflow.com/a/28589897/2944265. I am really confused now. –  Zveratko Mar 1 at 12:32
    
So thanks again for insight. I'm playing with Dart just to get rid of javascript, but forced to use this JS library it is a mess. I didn't thought Angular.Dart handles events, I thought it is javascript's job. –  Zveratko Mar 1 at 12:39
    
Your screenshot didn't provide enough information. I just had a look at your code in the repo and from this I can tell that Angular isn't involed with the event. I looked briefly at the code examples but I can't tell why the event in the linked question didn't arrive in the same form as in your current code. –  Günter Zöchbauer Mar 1 at 12:50

1 Answer 1

up vote 0 down vote accepted

The debugger shows it is already a JsObject, just omit the new JsObject(...) call.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.