Try cloak with css property visibility hidden/visible which allows elements to still affect layout.