Prevent empty views blocks from getting rendered even if they are empty.
Issue:
Sometimes blocks are rendered even when they are empty and even if the setting in views is activated that they should not be rendered when empty. This might be the case in combination i.e. with lazy loading. If an empty block is rendered, this may have impact on the layout because the empty block might still have margins or paddings
Solution:
This snippet replaces the generic Views block and checks "manually" whether or not the block is empty.