Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: expose the validation failure reasons for developers to check against #382

Merged
merged 1 commit into from
Dec 21, 2024

Conversation

JamesLMilner
Copy link
Owner

Description of Changes

This PR exposes all the internal validation failure reasons to make it easier for developers using Terra Draw to have branching logic depending on the failure reason, even if the wording of the error was to change in the future (for example due to a typo or clarification change).

import { ValidationReasons } from 'terra-draw';

const { ValidationReasonFeatureHasHoles } = ValidationReasons

console.log(ValidationReasonFeatureHasHoles)

Link to Issue

#380

PR Checklist

  • The PR title follows the conventional commit standard
  • There is a associated GitHub issue
  • If I have added significant code changes, there are relevant tests
  • If there are behaviour changes these are documented

@JamesLMilner JamesLMilner force-pushed the export-validation-reasons branch from c8ca147 to 9d119c6 Compare December 21, 2024 11:25
@JamesLMilner JamesLMilner merged commit c9e7711 into main Dec 21, 2024
6 checks passed
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