title: How to list all products with total sales?
body: <p>How to list all products from WooCommerce with total sales? This code is just for 1 product only. It's not work if put an array on $product.</p>
  
  <pre><code>&lt;?php
  $product = "13";
  $units_sold = get_post_meta( $product, 'total_sales', true );
  echo '&lt;p&gt;' . sprintf( __( 'Units Sold: %s', 'woocommerce' ), $units_sold ) . '&lt;/p&gt;';
  ?&gt;
  </code></pre>
  
  <p>I want on output, format will be like this:</p>
  
  <pre><code>[PRODUCT_NAME] - [TOTAL_SALES]
  </code></pre>