Skip to content

Commit

Permalink
Fix esModule flagging breaking in native ESM mode
Browse files Browse the repository at this point in the history
  • Loading branch information
t2t2 committed Jan 9, 2022
1 parent eacee11 commit ecc17c2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -371,5 +371,7 @@ export abstract class BaseOBSWebSocket extends EventEmitter<MapValueToArgsArray<
}

// https://github.com/developit/microbundle/issues/531#issuecomment-575473024
// eslint-disable-next-line @typescript-eslint/naming-convention
Object.defineProperty(exports, '__esModule', {value: true});
// Not using ESM export due to it also being detected and breaking rollup based bundlers (vite)
if (typeof exports !== 'undefined') {
Object.defineProperty(exports, '__esModule', {value: true});
}

0 comments on commit ecc17c2

Please sign in to comment.