Question

I am trying to override an html file in the lib folder, but I cant get it to work. Here is what I have so far:

Path to file I want to override: /lib/web/mage/gallery/gallery.html

Path to file I want to override with: /app/design/frontend/{Module}/{Theme}/web/mage/gallery/gallery.html

I have flushed the cache, but it still only loads the original file.

Any help with this would be appreciated.

Update: If I delete the lib files, it will use the files I want to use, but I want to override the lib files, not have to delete them.

Was it helpful?

Solution

I think you missed something with clearing cache.

Copy file to

 /app/design/frontend/<vendor>/<theme>/web/mage/gallery/gallery.html
  1. Clear cache and delete pub/static/frontend

  2. Deploy static content (if you in production mode)

  3. Clear browser cache.

Licensed under: CC-BY-SA with attribution
Not affiliated with magento.stackexchange
scroll top