Magento 2 - Show swatches of simple products (out of stock) in configurable product

2018-01-13 00:26:51

Magento versión: 2.1.7

I have a configurable product with ALL its simple products without stock.

I need to show in the configurable product the swatches of size / color (disabled) of their associated simple products.

Is this possible?

I already developed a modification and if at least 1 simple product has stock it shows all the swatches (available and not available).

The problem is if there's no stock of any simple product of configurable.