extends HTMLElement not working
This means that customElements which is now in most evergreen browsers don't work.
Perhaps this issue is related to this.constructor sometimes being broken. This is how Babel transpiles:
class ConversationBlock extends AnyBlock {
get props() {
return {
id: { attribute: true }
};
}
}
var ConversationBlock = (function (AnyBlock$$1) {
function ConversationBlock () {
AnyBlock$$1.apply(this, arguments);
}
if ( AnyBlock$$1 ) ConversationBlock.__proto__ = AnyBlock$$1;
ConversationBlock.prototype = Object.create( AnyBlock$$1 && AnyBlock$$1.prototype );
ConversationBlock.prototype.constructor = ConversationBlock;
var prototypeAccessors = { props: {} };
prototypeAccessors.props.get = function () {
return {
id: { attribute: true }
};
};
Original text:
ThreadAction.prototype = Object.create( HTMLElement && HTMLElement.prototype );
ThreadAction.prototype.constructor = ThreadAction;
Assigning the constructor failed on Safari for El Cap with constructor being read-only.
However with the latest Safari 10.0 upgrade it doesn't seem to be a problem. I guess that removes the issue long term, but short term I'd expect to see Safari 9 around.
It seems TypeScript has dealt with this already.