updateConfig(cfgToAdd) {
    // Teardown all previous configs
    this.teardown();

    /**
     * @type {OverlayConfig}
     * @private
     */
    this.__prevConfig = this.config;

    /** @type {OverlayConfig} */
    this.config = {
      ...this._defaultConfig, // our basic ingredients
      ...this.__sharedConfig, // the initial configured overlayController
      ...cfgToAdd, // the added config
      popperConfig: {
        ...(this._defaultConfig.popperConfig || {}),
        ...(this.__sharedConfig.popperConfig || {}),
        ...(cfgToAdd.popperConfig || {}),
        modifiers: [
          ...(this._defaultConfig.popperConfig?.modifiers || []),
          ...(this.__sharedConfig.popperConfig?.modifiers || []),
          ...(cfgToAdd.popperConfig?.modifiers || []),
        ],
      },
    };

    /** @private */
    this.__validateConfiguration(this.config);
    /** @protected */
    this._init();
    /** @private */
    this.__elementToFocusAfterHide = undefined;

    if (!this.#isRegisteredOnManager()) {
      this.manager.add(this);
    }
  }
Allows to dynamically change the overlay configuration. Needed in case the
presentation of the overlay changes depending on screen size.
Note that this method is the only allowed way to update a configuration of an
OverlayController instance.
@param { OverlayConfig } cfgToAdd