code: function validate(config, ruleMapper, envContext, source = null) {
      validateConfigSchema(config, source);
      validateRules(config.rules, ruleMapper, source);
      validateEnvironment(config.env, envContext, source);
      validateGlobals(config.globals, source);
  
      for (const override of config.overrides || []) {
          validateRules(override.rules, ruleMapper, source);
          validateEnvironment(override.env, envContext, source);
      }
  }
docs: Validates an entire config object.
  @param {Object} config The config object to validate.
  @param {function(string): {create: Function}} ruleMapper A mapper function from rule IDs to defined rules
  @param {Environments} envContext The env context
  @param {string} source The name of the configuration source to report in any errors.
  @returns {void}