Change record status: 
Project: 
Introduced in branch: 
11.3.x
Introduced in version: 
11.3.0
Description: 

A new service, Drupal\Core\Config\ConfigImporterFactory::class has been added which allows creation of a ConfigImporter object.

This should be used rather than instantiating the ConfigImporter class directly.

Before:

$config_importer = new ConfigImporter(
  $storage_comparer,
  \Drupal::service('event_dispatcher'),
  \Drupal::service('config.manager'),
  \Drupal::service('lock.persistent'),
  \Drupal::service('config.typed'),
  \Drupal::service('module_handler'),
  \Drupal::service('module_installer'),
  \Drupal::service('theme_handler'),
  \Drupal::service('string_translation'),
  \Drupal::service('extension.list.module'),
  \Drupal::service('extension.list.theme')
);

After:

$config_importer = \Drupal::service(Drupal\Core\Config\ConfigImporterFactory::class)->get($storage_comparer);
Impacts: 
Module developers