https://github.com/pauldijou/reactivemongo-play-validation
Play Framework ReactiveMongo plugin using Validation API
https://github.com/pauldijou/reactivemongo-play-validation
Last synced: 2 months ago
JSON representation
Play Framework ReactiveMongo plugin using Validation API
- Host: GitHub
- URL: https://github.com/pauldijou/reactivemongo-play-validation
- Owner: pauldijou
- License: apache-2.0
- Created: 2014-08-22T05:36:35.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2014-08-22T05:42:19.000Z (almost 11 years ago)
- Last Synced: 2025-02-04T20:43:54.494Z (4 months ago)
- Language: Scala
- Size: 129 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# ReactiveMongo support for Play! and Validation API
This is just an extension of the original [Play ReactiveMongo](https://github.com/ReactiveMongo/Play-ReactiveMongo) plugin for Play! Framework. It just replaces the default JSONCollection, which use `Reads` and `Writes` from the JSON lib with `Rule` and `Write` from the [Validation API](jto.github.io/validation).
## Usage
In your `build.sbt` or `project.Build.scala`
~~~ scala
resolvers += "Sonatype Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots/"libraryDependencies ++= Seq(
"org.reactivemongo" %% "reactivemong-play2-validation" % "0.11.0-SNAPSHOT"
)
~~~Then, it is exactly just like the original [Play ReactiveMongo plugin](https://github.com/ReactiveMongo/Play-ReactiveMongo/blob/master/README.md) for configuration and stuff. The only difference is to use `play.modules.reactivemongo.validation.collection.JSONCollection` instead of `play.modules.reactivemongo.json.collection.JSONCollection`. And that's it!
## Resources
- [ReactiveMongo](http://reactivemongo.org)
- [Original Play ReactiveMongo plugin](https://github.com/ReactiveMongo/Play-ReactiveMongo)
- [Validation API](https://jto.github.io/validation)
- [Play Framework](https://www.playframework.com)