Indicates that this field contains a primitive value (or Date) which should be serialized literally to json.
Optional
optional object that contains beforeDeserialize and/or afterDeserialize handlers
createModelSchema(Todo, { title: primitive(),})serialize(new Todo('test')) // { "title": "test" } Copy
createModelSchema(Todo, { title: primitive(),})serialize(new Todo('test')) // { "title": "test" }
Indicates that this field contains a primitive value (or Date) which should be serialized literally to json.