Skip to main content

no-trailing-leading-spaces-in-schema-enum-element-name

Overview

This rule belongs to the openapi-v3-codegen-syntax-linting ruleset and states that:

Name of a schema enum element should not contain any leading or trailing white-space characters.

PropertyValue
EnabledYes
Maximum SeverityWarning
MessageLeading or trailing white-space characters found in enum item name defined in x-enum-elements extension.
CodeOPENAPI3CODEGENSYNTAX_L613
TypeLinting
Rule SystemSyntax
Broad CategoryOpenAPI Schemas
Products ImpactedCode Generation, Developer Experience Portal
Tagscode generation sdks openapi3 openapi syntax linting apimatic schema enum name x-enum-element leading trailing whitespace character

Suggested Fixes

  • Remove all leading or trailing white-space characters such as spaces, tabs, or line breaks from enum item name.

For More Information