We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 607f42f commit 67dee41Copy full SHA for 67dee41
src/__tests__/pretty-dom.js
@@ -1,14 +1,15 @@
1
+/* global globalThis */
2
import {prettyDOM as prettyDOMImpl} from '../pretty-dom'
3
import {render, renderIntoDocument} from './helpers/test-utils'
4
5
function prettyDOM(...args) {
6
let originalProcess
7
// this shouldn't be defined in this environment in the first place
- if (typeof process !== 'undefined') {
8
+ if (typeof process === 'undefined') {
9
+ throw new Error('process is no longer defined. Remove this setup code.')
10
+ } else {
11
originalProcess = process
12
delete globalThis.process
- } else {
- throw new Error('process is no longer defined. Remove this setup code.')
13
}
14
15
try {
0 commit comments