Parsley is a JavaScript library, that can work with both jQuery or Zepto, designed to validate forms easily. It is built with UX concerns in mind and tries to simplify details for the user.

Is this what you're looking for?

Answer from Diego Cardozo on Stack Overflow
🌐
Stackshare
stackshare.io β€Ί npm-validate-js β€Ί alternatives
validate.js Alternatives
Explore the pros & cons of validate.js and its alternatives. Learn about popular competitors like jQuery, React, and AngularJS
Discussions

Replace jQuery Validation Plugin with a dependency-free alternative
According to the section on Form Validation: By default, WFP recommends a jQuery Validation Plugin, which is well documented and actively supported. Please, refer to its documentation for ways to i... More on github.com
🌐 github.com
13
March 17, 2016
JS validator alternatives to JSLint? - javascript
Is JSLint it as far as js validation tools go, or are there others? More on stackoverflow.com
🌐 stackoverflow.com
node.js - npm "validator" vs "express-validator" - Stack Overflow
I am new to Node JS and haven't used any of these modules. Can I please ask for help on which of these two validators is better and more efficient to use? validator: https://www.npmjs.com/package/ More on stackoverflow.com
🌐 stackoverflow.com
Any alternatives to this simple Javascript validation? - Stack Overflow
Can anyone tell me what are the alternatives to validate user input? this is just a very basic code I wrote today. there is a button coded in HTML when the user click on it, it will prompt for in... More on stackoverflow.com
🌐 stackoverflow.com
June 12, 2017
🌐
npm Trends
npmtrends.com β€Ί joi-vs-validate.js-vs-validator
joi vs validate.js vs validator | npm trends
Comparing trends for joi 18.0.1 which has 13,592,128 weekly downloads and 21,155 GitHub stars vs. validate.js 0.13.1 which has 561,950 weekly downloads and 2,616 GitHub stars vs. validator 13.15.15 which has 15,239,971 weekly downloads and 23,579 GitHub stars.
🌐
GitHub
github.com β€Ί wfp β€Ί ui β€Ί issues β€Ί 81
Replace jQuery Validation Plugin with a dependency-free alternative Β· Issue #81 Β· wfp/designsystem
March 17, 2016 - According to the section on Form Validation: By default, WFP recommends a jQuery Validation Plugin, which is well documented and actively supported. Please, refer to its documentation for ways to i...
Author Β  andrewholgate
🌐
npm Trends
npmtrends.com β€Ί just-validate-vs-pristinejs-vs-validate.js-vs-validator.js-vs-validatorjs
just-validate vs pristinejs vs validate.js vs validator.js vs validatorjs | npm trends
Comparing trends for just-validate 4.3.0 which has 7,062 weekly downloads and 585 GitHub stars vs. pristinejs 1.1.0 which has 3,559 weekly downloads and 433 GitHub stars vs. validate.js 0.13.1 which has 695,413 weekly downloads and 2,615 GitHub ...
Find elsewhere
🌐
DEV Community
dev.to β€Ί shanu001x β€Ί top-5-validation-libraries-for-javascript-in-2024-35la
Top 5 Validation Libraries for JavaScript in 2024 - DEV Community
August 3, 2024 - Joi and Yup are excellent for server-side and client-side validation. Validator.js is perfect for straightforward string validation, and class-validator is great for TypeScript and NestJS projects.
Top answer
1 of 2
11

They are used for different scenarios:

  • validator is a library to validate any kind of object and it's not associated with any framework.

  • express-validator uses validator library to validate expressjs routes. Basically you can validate express routes out of the box using validator lib.

In my honest opinion you can easily create your own validator middleware. Specially if you are new to Node.js it will help you to understand how middlewares work. If you are not interested on that and you have an express application feel free to use express-validator

Also I really recommend JOI as a validator lib https://github.com/hapijs/joi it's simple and it works well.

Here is an example of a middleware (I have not tested)

const Joi = require('joi')
module.exports = function validate(joiSchema) {
  return async (req, res, next) => {
    const result = Joi.validate(req.body, joiSchema, {
      allowUnknown: true,
      abortEarly: false
    })

    if (result.error) {
      throw new result.error
    }

    await next()
  }
}

  // express route
  router.post(
    '/create',
    validateMiddleware({
      body: {
        body: { firstName: Joi.string(), lastName: Joi.string() }
      }
    }),
    (req, res, next) => {
    // your logic
   })
2 of 2
0

Express-validator is used as middleware, the idea with express-validator is to check bad input before it reaches your controller.

Now, if you are using validator, you can make your own validation function in which you will simply pass the data and it will tell if the input is in accordance to it (Just like checking an Email, here you can have a function, which will check if input given to it is a function or not).

In case you are using Services in your structure, then you can use validator as I feel it's easy and of more control than express-validator

🌐
GitHub
github.com β€Ί validatorjs β€Ί validator.js
GitHub - validatorjs/validator.js: String validation Β· GitHub
For an alternative, have a look at Yahoo's xss-filters library or at DOMPurify. ... Remember, validating can be troublesome sometimes.
Starred by 23.8K users
Forked by 2.4K users
Languages Β  JavaScript
🌐
Libhunt
js.libhunt.com β€Ί validate-js-alternatives
validate.js Alternatives - JavaScript Validation | LibHunt
March 2, 2020 - Lightweight JavaScript form validation library inspired by CodeIgniter. Tags: Validation, Validate, Browser, Browserify, Client, DOM, Form, Server.
🌐
GitHub
github.com β€Ί vlucas β€Ί vlid
GitHub - vlucas/vlid: Lightweight validation library with NO dependencies. A nice Joi alternative with a similar API.
May 20, 2019 - Lightweight Joi-like validation library with NO dependencies targeting web browsers and Node.js. A nice Joi alternative with a similar API.
Starred by 64 users
Forked by 6 users
Languages Β  JavaScript 99.7% | Shell 0.3% | JavaScript 99.7% | Shell 0.3%
🌐
Libhunt
js.libhunt.com β€Ί validator-js-alternatives
validator.js Alternatives - JavaScript Validation | LibHunt
Based on the "Validation" category. Alternatively, view validator.js alternatives based on common mentions on social networks and blogs.
🌐
Reddit
reddit.com β€Ί r β€Ί typescript β€Ί comments β€Ί unu8ps β€Ί whats_your_favorite_data_validation_library_zod
r/typescript on Reddit: What's your favorite data validation library? Zod, myzod, io-ts, etc
May 12, 2022 - Here's a performance comparison of most Typescript-compatible validation libraries including Yup. joi is not included because it's JS only, but you can see that Yup is the slowest option by far.
🌐
Libhunt
js.libhunt.com β€Ί jquery-validation-alternatives
jquery-validation Alternatives - JavaScript Validation | LibHunt
November 12, 2025 - Allows writing the same validation logic for the client and server side. ... KnexBridge β€” A TypeScript monorepo that introspects Knex databases and generates clean TypeScript types and Zod schemas automatically. * Code Quality Rankings and insights are calculated and provided by Lumnify. They vary from L1 to L5 with "L5" being the highest. Do you think we are missing an alternative of jquery-validation or a related project?
🌐
Libhunt
js.libhunt.com β€Ί vee-validate-alternatives
vee-validate Alternatives - JavaScript Validation | LibHunt
1 month ago - Do you think we are missing an alternative of vee-validate or a related project? Add another 'Validation' Library Β· InfluxDB – Database Purpose-Built for High-Resolution Data ... 🏏 Minimal: Only handles the complicated form concerns, gives you full control over everything else Β· 😎 UI Agnostic: Works with native HTML elements or your favorite UI library components Β· 🦾 Progressive: Works whether you use Vue.js as a progressive enhancement or in a complex setup
🌐
Libhunt
js.libhunt.com β€Ί parsley-js-alternatives
Parsley.js Alternatives - JavaScript Validation | LibHunt
DISCONTINUED. The best @jquery plugin to validate form fields. Designed to use with Bootstrap + Zurb Foundation + Pure + SemanticUI + UIKit + Your own frameworks. 6.1 0.0 Parsley.js VS jQuery.validationEngine v2.6.2