File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed
packages/node_modules/overmind-devtools/src Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -168,9 +168,26 @@ function createWindow() {
168168 )
169169
170170 startDevtoolBackend ( ) . then ( openDevtools )
171+
172+ /*
173+ BUG FIX: https://github.com/electron/electron/issues/13008#issuecomment-575909942
174+ */
175+ let redirectURL = 'data:application/x-javascript;base64,UHJvZHVjdFJlZ2lzdHJ5SW1wbC5SZWdpc3RyeT1jbGFzc3tjb25zdHJ1Y3Rvcigpe31uYW1lRm9yVXJsKHIpe3JldHVybiBudWxsfWVudHJ5Rm9yVXJsKHIpe3JldHVybiBudWxsfXR5cGVGb3JVcmwocil7cmV0dXJuIG51bGx9fSxQcm9kdWN0UmVnaXN0cnlJbXBsLl9oYXNoRm9yRG9tYWluPWZ1bmN0aW9uKHIpe3JldHVybiIifSxQcm9kdWN0UmVnaXN0cnlJbXBsLnJlZ2lzdGVyPWZ1bmN0aW9uKHIsdCl7UHJvZHVjdFJlZ2lzdHJ5SW1wbC5fcHJvZHVjdHNCeURvbWFpbkhhc2g9bmV3IE1hcH0sUHJvZHVjdFJlZ2lzdHJ5SW1wbC5fcHJvZHVjdHNCeURvbWFpbkhhc2g9bmV3IE1hcCxQcm9kdWN0UmVnaXN0cnlJbXBsLnJlZ2lzdGVyKFtdLFtdKSxQcm9kdWN0UmVnaXN0cnlJbXBsLnNoYTE9ZnVuY3Rpb24ocil7cmV0dXJuIiJ9Ow==' ;
176+ electron . session . defaultSession . webRequest . onBeforeRequest ( ( details , callback ) => {
177+ if ( ( / ^ d e v t o o l s : \/ \/ d e v t o o l s \/ r e m o t e \/ s e r v e _ f i l e \/ @ [ 0 - 9 a - f ] { 40 } \/ p r o d u c t _ r e g i s t r y _ i m p l \/ p r o d u c t _ r e g i s t r y _ i m p l _ m o d u l e .j s $ / ui) . test ( details . url ) ) {
178+ // eslint-disable-next-line
179+ callback ( {
180+ redirectURL
181+ } ) ;
182+ return ;
183+ }
184+ // eslint-disable-next-line
185+ callback ( { } ) ;
186+ } ) ;
171187}
172188
173189// This method will be called when Electron has finished
174190// initialization and is ready to create browser windows.
175191// Some APIs can only be used after this event occurs.
176192app . on ( 'ready' , createWindow )
193+
You can’t perform that action at this time.
0 commit comments