Skip to content

Adds prop-validation modes throw-warn-off - #83

Merged
koculu merged 2 commits into
mainfrom
prop-validation-mode-throw-warn-off
Apr 5, 2026
Merged

koculu merged 2 commits into
mainfrom
prop-validation-mode-throw-warn-off

Conversation

@koculu

@koculu koculu commented Apr 5, 2026 •

Copy link
Copy Markdown
Member

Summary

Adds configurable runtime prop-validation handling through RegorConfig.propValidationMode.

This changes head.validateProps(...) from always throwing to following app config:

  • 'throw' keeps the current fail-fast behavior
  • 'warn' reports validation failures through warningHandler.warning(...) and continues
  • 'off' disables runtime prop validation entirely

Included

  • RegorConfig.propValidationMode with 'throw' | 'warn' | 'off'
  • wiring from app config into component prop validation
  • tests covering all three modes
  • documentation updates across README and docs-site for config-driven validation behavior
  • improved prop-validation error reporting and custom-validator ergonomics.

@koculu
koculu merged commit ab40e40 into main Apr 5, 2026
1 check passed
@koculu
koculu deleted the prop-validation-mode-throw-warn-off branch April 5, 2026 23:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant