An incomplete(able) list of ways I've seen Data Types Documentation done. # [[TypeScript]] Does **not** include sanitization on [[Domain and Range#Range Validity]]. ```typescript interface Measurement{ id: string type: MyTypeEnum //defined elsewhere unit: MyUnitEnum //defined elsewhere amount: number } ``` # [[Pkl]] **Does** include features for [[Domain and Range#Range Validity]]. You can create your own [[Predicate Function]]s for it. ```pkl port: Int(this > 1000) ``` # [[OWL]] **Does** include features for [[Domain and Range#Range Validity]]. ```Turtle  :personAge owl:equivalentClass [ rdf:type rdfs:Datatype; owl:onDatatype xsd:integer; owl:withRestrictions ( [ xsd:minInclusive "0"^^xsd:integer ] [ xsd:maxInclusive "150"^^xsd:integer ] ) ] . ``` # [[JSON Schema]] **Does** include features for [[Domain and Range#Range Validity]]. Several types. ```JSON { "type": "number" "multipleOf": 10 "inclusiveMinimum": 0 "exclusiveMaximum": 101 //although 101 would be invalid as not a multiple of 10 } ``` **** ## Source - https://www.w3.org/TR/owl2-primer/#Property_Characteristics - https://pkl-lang.org/ ## Related - [[JSON Schema]]