Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save Erchiragdodia/8f4a22c8c6bf7c8dba60d66d40bb80c1 to your computer and use it in GitHub Desktop.

Select an option

Save Erchiragdodia/8f4a22c8c6bf7c8dba60d66d40bb80c1 to your computer and use it in GitHub Desktop.
Magento2: Find cacheable="false" in layout XML
# execute in Magento 2 root:
find vendor app -regextype 'egrep' -type f -regex '.*/layout/.*\.xml' -not -regex '.*(vendor/magento/|/checkout_|/catalogsearch_result_).*' | xargs grep --color -rnw -e 'cacheable="false"'
# by https://MageHost.pro
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment