-
Notifications
You must be signed in to change notification settings - Fork 129
Description
I am looking for a way to add syntax validation with human readable error messages to https://trafficsigns.osm-verkehrswende.org/DE?signs=DE:274-30,1042-31[Di-So+12:00-13:00] where the input field is the values that is used in the *:conditional tag.
What is the recommended way to do this?
It looks like the only way is to try-catch new opening_hours(myValue) and return that? But that does not feel right and I don't understand, yet, how getWarnings and the config option locale (which would return translated error messages?) work with this.
I set up a test case at https://stackblitz.com/edit/stackblitz-starters-crgml78u?file=app%2Fpage.tsx to test this in isolation.
What I am looking for is a list of error messages, ideally translated to the given language, that explain what is wrong and how to fix the syntax.
Any hints are appreciated!