1. In Vanilla magento2, the file path showing original file path as you can see in below screenshot the file path is showing from vendor after doc root.enter image description here
  2. In one of my working project where cache path is showing.enter image description here
  3. I am facing an issue in Xdebug where the debugger is stopping on cache files instead of actual file. Is this related Magneto configuration? If yes, can anyone share your thoughts on this.
  • What is the issue?
    – Aaron Wang
    Commented Jan 11, 2023 at 20:56
  • @WangGang the main issue is cache path i.e var/view_preprocessed/pub/static should not show in template path. Usually while debugging we don't keep break point in cache file instead we keep it at actual file. Somehow due to this template path issue I have to keep break point at cache file. Commented Jan 13, 2023 at 9:11

1 Answer 1


When the minify HTML feature is enabled in your project, Magento will retrieve the phtml template files from the cached directory, specifically located in the var/view_preprocessed/pub/static directory. As a result, when template hints are displayed, they will show the template path from the cache instead of the original file path.

To disable the minify HTML feature, use the following command:
bin/magento config:set dev/template/minify_html 0

Afterward, clear the config cache type to see the changes by running the command:
bin/magento cache:clean config

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.