npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@dmc12/validationform

v1.0.0

Published

Validation form for demo of validation lib

Downloads

2

Readme

Form Validation App

This is a form validation app that uses a validation library to check if input fields meet certain criteria. The validation library is imported from dmc-validation-lib and contains functions for validating different types of data such as email addresses, phone numbers, passwords, credit card numbers, and empty fields. The app also includes a range validation function to check if a number falls within a specified range.

Getting Started

To get started with this app, simply clone this repository to your local machine and open the index.html file in your browser.

How to Use

The app includes several input fields that need to be validated. Each input field has two corresponding status elements that indicate whether the input is valid or not. The status elements are hidden by default and will only be displayed if the input is invalid.

To validate an input field, simply type in the desired value and the validation function will be triggered automatically. If the input is valid, the green checkmark status element will be displayed. If the input is invalid, the red cross status element will be displayed instead.

Validation Functions

The following validation functions are included in this app:

notEmptyValidation: checks if an input field is empty. isComplexPassword: checks if a password meets complexity requirements (at least 8 characters, includes uppercase and lowercase letters, and includes at least one number and one special character). isValidPhoneNumber: checks if a phone number is valid (must be in the format XXX-XXX-XXXX). isValidEmail: checks if an email address is valid (must be in the format [email protected]). isValidCreditCard: checks if a credit card number is valid (must be a valid Visa, Mastercard, or American Express card number). isInRange: checks if a number falls within a specified range.

Range Validation

The range validation function allows you to check if a number falls within a specified range. To use this function, simply enter the minimum and maximum values of the range in the corresponding input fields. Then, enter the number you want to check in the "Value to Check" input field. The status elements will display whether the value falls within the range or not.

Technologies Used

HTML CSS JavaScript dmc-validation-lib

Contributing

Contributions to this project are welcome. To contribute, simply fork this repository, make your changes, and submit a pull request.