Decision Enforce SDC Schema Validation

accepted

Without enforced schema validation, Single Directory Components can silently accept incorrect or missing props, leading to runtime errors and inconsistent rendering.

Decision

Enable enforce_prop_schemas: true in the theme's .info.yml to require schema validation for all SDC components.

Exceptions

Projects still migrating legacy templates to SDC may defer enforcement until migration is complete.

Consequences

  • Invalid or missing props are caught during development rather than silently failing
  • Component contracts are enforced, improving reliability across teams
  • Requires every SDC to have a valid *.component.yml schema before it will render

Additional Resources