File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6969 "eslint-plugin-prettier" : " ^3.4.0" ,
7070 "eslint-plugin-react" : " ^7.23.2" ,
7171 "eslint-plugin-react-hooks" : " ^4.2.0" ,
72+ "event-target-shim" : " ^6.0.2" ,
7273 "fetch-blob" : " ^2.1.1" ,
7374 "filter-console" : " ^0.1.1" ,
7475 "formdata-node" : " ^2.5.0" ,
Original file line number Diff line number Diff line change 11'use strict' ;
22
3- require ( 'abort-controller/polyfill' ) ;
3+ if ( ! ( 'performance' in global ) )
4+ global . performance = require ( 'perf_hooks' ) . performance ;
5+
6+ if ( ! ( 'EventTarget' in global ) )
7+ global . EventTarget =
8+ require ( 'events' ) . EventTarget || require ( 'event-target-shim' ) . EventTarget ;
9+
10+ if ( ! ( 'Event' in global ) )
11+ global . Event = require ( 'events' ) . Event || require ( 'event-target-shim' ) . Event ;
412
513if ( ! ( 'CustomEvent' in global ) )
614 global . CustomEvent = class CustomEvent extends Event {
@@ -10,8 +18,7 @@ if (!('CustomEvent' in global))
1018 }
1119 } ;
1220
13- if ( ! ( 'performance' in global ) )
14- global . performance = require ( 'perf_hooks' ) . performance ;
21+ require ( 'abort-controller/polyfill' ) ;
1522
1623const { TestDirector } = require ( 'test-director' ) ;
1724
You can’t perform that action at this time.
0 commit comments