Skip to content

Commit

Permalink
lint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
bencmbrook committed Jul 10, 2023
1 parent 796b5d5 commit c641840
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions src/event-target.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,27 @@
* Extend EventTarget to include the Transcend toStringTag
*/
export class TranscendEventTarget extends EventTarget {
#stringTag: string = 'Transcend';
#stringTag = 'Transcend';

get [Symbol.toStringTag]() {
console.log(this.#stringTag);
/**
* Add Transcend to the string tag
*
* @returns string
*/
get [Symbol.toStringTag](): string {
return this.#stringTag;
}

// Allow airgap.js code to overwrite [Symbol.toStringTag]
/**
* Allow airgap.js code to overwrite [Symbol.toStringTag]
*/
set [Symbol.toStringTag](updatedStringTag: string) {
this.#stringTag = updatedStringTag;
}

/**
* @param args - EventTarget constructor parameters
*/
constructor(...args: ConstructorParameters<typeof EventTarget>) {
super(...args);
}
Expand Down

0 comments on commit c641840

Please sign in to comment.