It's a common question how to show subcategories above the products on any given category view. In Magento 1 it was fairly straight forward; create a static block, add the necessary code to the template and show that block along with the products on said category.
But Magento 2 is quite different, and I figured out I could use two approaches:
- Create a module which does it for me
- Create a static block and show it with the category
For the first approach I found this code/module and this code which I applied to the category pages via XML, but it shows all the categories, in stead of only the current categories sub's. I tried to edit this but couldn't get it to work.
For the second approach, I figured I create a static block and assign it to the category in the adminpanel. All I did so far was create the static block, and what happens? It shows on every page in every sidebar and content block (so double on each page). This might be considered a separate question, but does anyone know why this happens?