How do I programmatically get the URL of an entity referenced media image field using on a custom_preprocess_html() hook on THEME.theme?
ok, here is what worked for me. After digging through stack overflow, found that I was missing the ImageStyle and this resulted in not rendering the url.

I added 

use Drupal\media\Entity\Media;
use Drupal\image\Entity\ImageStyle;
use Drupal\media_entity\MediaInterface;
use Drupal\node\Entity\Node;


and then on preprocess function, I loaded the media using the target_id that I got form the $node->field_image->target_id;

Then, I loaded the ImageStyle using 

$media = Media::load($image_id);
$media_url = ImageStyle::load('TYPE_OF_CROP')-&gt;buildUrl($media-&gt;image-&gt;entity-&gt;getFileUri());
$variables['media_url'] =  $media_url;


Hopefully this helps people.