DEV Community

Discussion on: Image Binding Error Handling in Vue.js

Collapse
 
jackwkinsey profile image
Jack Kinsey

I had recently found this solution too, but I noticed that the onerror attribute for img is deprecated according to MDN. My understanding is that @error boils down to onerror.

Still looking for an alternative though.

Collapse
 
zahidjabbar profile image
Zahid Jabbar

@error worked fine for me. Let me know if I can help you to solve your problem.

Collapse
 
jackwkinsey profile image
Jack Kinsey • Edited

Yeah we decided to go with this as it seems to work just fine and doesn't actually map directly to the onerror attribute. So all good it seems πŸ˜€