Validation of JSON-like structures with JSON Schemas through upickle's visitor framework.
val sch: Schema = json_schema.from(ujson.Readable, ujson.Readable.fromString("""{"type": "string"}"""))
val validator: Visitor[?, OutputUnit] = json_schema.validator(sch)
val result: OutputUnit = ujson.Str("foo").transform(validator)
Note: ujson is not a direct dependency of json-schema_3.
sbt
libraryDependencies += "io.github.jam01" % "json-schema_3" % "0.1.0"
Mill
ivy"io.github.jam01::json-schema_3::0.1.0"
Maven
<dependency>
<groupId>io.github.jam01</groupId>
<artifactId>json-schema_3</artifactId>
<version>0.1.0</version>
</dependency>