My question is inspired from this question
This is typescript inheritance code
var __extends = (this && this.__extends) || function (d, b) {
    for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
    function __() { this.constructor = d; }
    __.prototype = b.prototype;
    d.prototype = new __();
};
and I simplified version to this version
function extend(Destination, Base) {
    function Hook() { this.constructor = Destination; }
    Hook.prototype = Base.prototype;
    var hook = new Hook();
    Destination.prototype = hook;
};
and I draw graphical represantation inspired from here:
Could you confirm or correct ghaphical representation?
I especially did not understand this part:
function Hook() { this.constructor = Destination; }
And could you tell me how inheritance work with arguments and accompanied example

 
     
    