Skip to content

Instantly share code, notes, and snippets.

@gelanivishal
Created February 18, 2017 15:05
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save gelanivishal/1c76e8ea9f4d607ab0de3331d6410c28 to your computer and use it in GitHub Desktop.
Save gelanivishal/1c76e8ea9f4d607ab0de3331d6410c28 to your computer and use it in GitHub Desktop.
Debugging layout XML loading in Magento 2

Open following file :

{root}/vendor/magento/framework/View/Model/Layout/Merge.php

and find _loadFileLayoutUpdatesXml function at line number 681.

Just echo $file->getFilename(); in foerach. You can see list of layout xml files adding in that action.

You can also check other function of this file. They are very useful to debug layout xml in Magento 2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment