INNER CODE UNIT · JavaScript

ConfigSchemaHandler

serverless/serverless · packages/serverless/lib/classes/config-schema-handler/index.js:60

class ConfigSchemaHandler {
  constructor(serverless) {
    this.serverless = serverless
    this.schema = _.cloneDeep(schema)

    deepFreeze(this.schema.properties.service)
    deepFreeze(this.schema.properties.plugins)
    deepFreeze(this.schema.properties.package)
  }

  static getConfigurationValidationResult(configuration) {
    if (!configurationValidationResults.has(ensurePlainObject(configuration)))
      return null
    return configurationValidationResults.get(ensurePlainObject(configuration))
  }

  async validateConfig(userConfig) {
    if (!this.schema.properties.provider.properties.name) {

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…