Another great post by electronut labs. They write:
We really like Visual Studio Code editor for development. Their UI is very modern and slick, and they provide nice extensions which will make your coding tasks easier. I am going to talk about one useful extension for debugging here – Cortex Debug by marus25 (GitHub) – which adds debugging support for ARM Cortex-M Microcontrollers.
Cortex Debug on Visual Studio Code is very fast and efficient. I will show you how to set it up, and this setup is going to work with any nRF5x development boards. Later, I am going to show you how to debug on our nRF5x breakout board hackaBLE and program it using Bumpy, our SWD programmer.