9

Since the official Magento 2.0 forums aren't of any help, i'll post my question here as well.

We're in the process of building our own theme based on the Magento Blank theme and we would like to implement 2 small changes to the minicart dropdown in the header. These files are loaded through JS (Knockout.js framework), but simply duplicating the file to our own theme in the same folder (Name/name2/web/template/minicart/item/default.html) and editing them doesn't show up any changes so we suspect the override behaviour is different in this case.

Can someone point us in the right direction? Thanks!

Siarhey Uchukhlebau
  • 15,957
  • 11
  • 54
  • 83
  • 1
    We can use RequireJs to override the html templates. We can read more here: http://magento.stackexchange.com/questions/108788/how-to-override-template-files-for-magento2-extension/121702#121702 – Khoa TruongDinh Jun 19 '16 at 12:29

2 Answers2

3

This is the proper way to override the html file. I also had this issue, I think it's browser caching that prevents showing the changes. I do not have a real solution for this problem, but you can open the webshop in an incognito window each time you changed the .html file.

Silvan
  • 1,347
  • 6
  • 33
  • 55
2

This is proper way to override template file. You have to remove folder manually from pub/static/frontend/{{Package}}/{{theme}} folder and clear your browser cache.

Run command php bin/magento setup:static-content:deploy

Try load page and changes are display.

Thanks.

Rakesh Jesadiya
  • 42,221
  • 18
  • 132
  • 183