We talked here https://www.drupaldump.com/xdebug-and-docker4drupal-mac how to setup docker and xdebug, most people use phpstorm, but you could also use sublime editor with it, install with package commander xdebug client and then you will need to do some additional manual setup
{
"folders":
[
{
"follow_symlinks": true,
"path": "."
}
],
"settings":
{
"xdebug": {
"url": "http://commerce.local:8100",
"path_mapping": {"/var/www/html" : "/Users/Marko/Documents/Drupal/commerce_plain"
},
}
}
}
you need to set URL where your docker is sending requests, but also find the root path of your drupal installation and match the remote(docker path) with local path on your machine.
Also set your xdebug browser extension key to "sublime.xdebug".
When you set that up, you should have working XDEBUG. With all that, it is just poor UX that you will use just in dire need, its just better to fork out the money for PHPSTORM, the only decent IDE for drupal and work from there.