Short snippet to get the enabled languages programmatically

$langcodes = \Drupal::languageManager()->getLanguages();
$langcodesList = array_keys($langcodes);

 

 

 

Saved you some valuable time?

Received 100 so far from 4 kind contributors.