Debugging with PhpStorm: Xdebug starter guide

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ม.ค. 2025

ความคิดเห็น • 9

  • @saydfuad6914
    @saydfuad6914 2 หลายเดือนก่อน

    This is Perfect for debugging the flow of your code, but when it comes to seeing variables contents dd() work like magic.

  • @rcharamella
    @rcharamella หลายเดือนก่อน

    It looks like this does not work for OSX. Do you have other directions for OSX?

  • @imqqmi
    @imqqmi 2 หลายเดือนก่อน

    Xdebug is one of the first things I get working in a new environment. It's also great for TDD, writing tests and stepping through the code and inspecting variables to check if things are as expected. I hardly ever use echo, vardump or DD anymore, direct access to all variables values is much better than having to write dump (dumb) lines.
    The auto install is new to me, does this work for docker containers as well?
    I had a lot of issues with laravel sail and the scan for interpreter freezing phpstorm in v2024.2.3. it doesn't seem to like the xdebug env vars in docker-compose. Getting xdebug working for web requests, cli and unit tests with docker can be quite challenging, esp. in combination with windows/wsl and how and where local files are stored in mapped drive into wsl Vs unc Vs local drive.
    Even though it's a challenge, I've found it always paid dividends in the long run.

  • @eduardpertinez4767
    @eduardpertinez4767 2 หลายเดือนก่อน

    It would be great if you went through every little button of the debugger. I am sure I am not using it as it is supposed. For example... where are you supposed to write down the statements you want to evaluate in real time once you stop the program? In vscode you have a list that stays there between runs.

  • @supportic
    @supportic 2 หลายเดือนก่อน

    Now with docker and make it toggle-able please

  • @cichy86
    @cichy86 2 หลายเดือนก่อน +7

    Xdebug is the second best debugger for PHP. Pair echo 'test'; and var_dump($variable) is first

  • @ukyo6195
    @ukyo6195 2 หลายเดือนก่อน

    Never used this one