@midget2000x wrote:
Not that it really matters that much, but I was curious if there was a way to access an HTML element in a component without using this.$()
Example:
export default Component.extend({ tagName: 'img', attributeBindings: ['src'], didInsertElement() { let _this = this; this.$().on('error', function() { _this.set('src', missingImage); }); }, willDestroyElement() { this.$().off(); } });
Like, how could I access the element with plain javascript?
Posts: 2
Participants: 2