Mongoid plugin for ClientSideValidations
Latest commit a6e2992 Sep 10, 2016 @tagliala tagliala Update version


Gem Version Build Status Dependency Status Code Climate Coverage Status

Mongoid plugin for ClientSideValidations


In your Gemfile add the following:

gem 'mongoid'
gem 'client_side_validations'
gem 'client_side_validations-mongoid'

Order matters here. Mongoid and ClientSideValidations need to be required before ClientSideValidations-Mongoid.

Follow the remaining installation instructions for ClientSideValidations


The usage is the same as ClientSideValidations, just pass validate: true to the form builder

<%= form_for @book, validate: true do |book| %>
  <%= book.input :name %>
<% end %>

Per-input options are done with :validate

<%= book.input :name, validate: { presence: true, uniqueness: false }


Brian Cardarella

Geremia Taglialatela

We are very thankful for the many contributors


This gem follows Semantic Versioning

Major and minor version numbers will follow mongoid's major and minor version numbers. For example, client_side_validations-mongoid-5.1.0 will be compatible up to ~> mongoid-5.1

Want to help?

Please do! We are always looking to improve this gem. Please see our Contribution Guidelines on how to properly submit issues and pull requests.


DockYard, LLC © 2012-2016


Licensed under the MIT license