I am using Visual Code to developer a React/ NextJS application. I run the application using 'npm run dev'. Each time I save a source code file Safari gets updates AND the takes over (focuses on Safari) and I lose my editor focus.

I still want to get the hot loading of the debug function. I just don't want the focus to switch to Safari. This is relatively new behaviour as it was not like this before.

Can I manage focus better on macOS to avoid this context switch?

  • Did you find a solution to this?
    – Espen
    Commented Jul 4, 2023 at 1:50
  • I have not. I have switched to development on Firefox which does not have the issue. Bummer
    – checklist
    Commented Jul 4, 2023 at 5:02


You must log in to answer this question.

Browse other questions tagged .