How to get all parent nodes from a menu item?
I don't think there's anything as simple as $menuLinkContent->getTargetEntity()->getType(). Though that would be nice and I'd love for someone to correct me on that. 

Below I wrote a method that loads the menu, loops through the menulink objects, grabs the url objects from them and loads the nodes based on the path of the url object. Once it has the node it gets the content type from it. I doubt it's better performance wise, but it does take advantage of more of the out of the box stuff and might be a bit easier to read. 

$menu_tree = \Drupal::menuTree();
$menu = reset(\Drupal::entityTypeManager()-&gt;getStorage('menu')-&gt;loadByProperties(['uuid' =&gt; $uuid]));
$menu_parameters = $menu_tree-&gt;getCurrentRouteMenuTreeParameters($menu-&gt;id());
$menu_tree_elements = $menu_tree-&gt;load($menu-&gt;id());

foreach($menu_tree_elements as $menu_tree_element){
    $path = $menu_tree_element-&gt;link-&gt;getUrlObject()-&gt;toString();
    $node = self::nodeFromPath($path);
    $contentType = $node-&gt;getType();
    foreach($menu_tree_elements-&gt;subtree as $subtree_menu_element){
        $path = $subtree_menu_element-&gt;link-&gt;getUrlObject()-&gt;toString();
        $node = self::nodeFromPath($path);
        $contentType = $node-&gt;getType();             
    }
}

function nodeFromPath($path){
        $path = \Drupal::service('path.alias_manager')
            -&gt;getPathByAlias($path);
        preg_match('/node\/(\d+)/', $path, $matches)) {
        $nid = $matches[1];
        return Node::load($nid);
}