Skip to content

Instantly share code, notes, and snippets.

@thebigdatajedi
Created December 17, 2022 13:43
Show Gist options
  • Save thebigdatajedi/3099eae81c462f6f87d9bef941686bc3 to your computer and use it in GitHub Desktop.
Save thebigdatajedi/3099eae81c462f6f87d9bef941686bc3 to your computer and use it in GitHub Desktop.
You may never get a chance to use it. Who knows it may make a come back.
//tricky because it's becoming less and less supported but this is how you did it:
static callerName(func: Function): void {
let callingFunction: string = '';
callingFunction = func.caller.name;
const dateTime: string = this.getDateTime();
console.log('***-> ' + dateTime + ' <-###-> ' + func.name + ' is being called by: ' + callingFunction);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment