Closed Jaymon closed 1 year ago
It would be cool if you could pass in jsonable=False and it would strip that field from a .jsonable() call, so...
jsonable=False
.jsonable()
class Foo(Orm): bar = Field(str, jsonable=False) f = Foo(bar=4) f.jsonable() # empty dict {} because bar would be removed
if you pass in a regex then this will be ran during setting of the value, so...
class Foo(Orm): bar = Field(str, regex=r"[a-zA-Z]+")
Everytime bar gets set it would run regex to make sure bar conforms.
bar
regex
jsonable
It would be cool if you could pass in
jsonable=False
and it would strip that field from a.jsonable()
call, so...regex
if you pass in a regex then this will be ran during setting of the value, so...
Everytime
bar
gets set it would runregex
to make surebar
conforms.