Skip to content

Instantly share code, notes, and snippets.

@Colmea
Created January 18, 2016 09:02
Show Gist options
  • Save Colmea/04223a3224531061b3b8 to your computer and use it in GitHub Desktop.
Save Colmea/04223a3224531061b3b8 to your computer and use it in GitHub Desktop.
TypeError: _super.call is not a function(…)
// Generated JS file
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; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
define(["require", "exports", './GUIElement'], function (require, exports, GUIElement) {
var GUILayout = (function (_super) {
__extends(GUILayout, _super);
/**
* Constructor
* @param name layout name
* @param app App instance
*/
function GUILayout(name, app) {
_super.call(this, name, app);
}
}
[...]
import GUIElement = require('./GUIElement');
class GUILayout extends GUIElement implements IGUILayout {
// Public members
public panels: Array<GUIPanel> = new Array<GUIPanel>();
/**
* Constructor
* @param name layout name
* @param app App instance
*/
constructor(name: string, app: App) {
super(name, app);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment