It's almost the same as in Drupal 7, but in Drupal 8 the concept changes as OOP. So there is some difference to call the 'type'.
We can't simply call the type, we have to get the value of the type by function 'getType()'.
function THEME_NAME_preprocess_node(&$variables) {
if (!empty($variables['node']) && $variables['node']->getType() == 'my-type') {
$variables['title'] = 'MY TITLE';
}
}