Skip to content

Instantly share code, notes, and snippets.

@Gattermeier
Created November 29, 2015 05:36
Show Gist options
  • Save Gattermeier/53c0e3560804d2f5e2e8 to your computer and use it in GitHub Desktop.
Save Gattermeier/53c0e3560804d2f5e2e8 to your computer and use it in GitHub Desktop.
class ExternalClass {
constructor(someClassInstance, variable) {
this.someClassInstance = someClassInstance;
this.variable = variable;
}
}
class SomeClass {
constructor() {
}
doComething() {
let test = new ExternalClass(this, variable) // this is undefined
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment