simpleregistrationform
v1.0.0
Published
A simple user registration and login functionality with validation for email addresses and passwords.
Downloads
2
Readme
Simple Registration Form
This npm package provides a simple user registration and login functionality with validation for email addresses and passwords.
Installation
You can install this package using npm:
npm install simpleregistrationform
Usage
To use the registration and login functionality, import the module and call the respective functions:
const { registerUser, userExists, loginUser } = require('simpleregistrationform');
// Register a new user
const registrationResult = registerUser('[email protected]', 'Password123', 'users.json');
console.log(registrationResult);
// Check if a user exists
const userExistsResult = userExists('[email protected]', 'users.json');
console.log(userExistsResult);
// Login with user credentials
const loginResult = loginUser('[email protected]', 'Password123', 'users.json');
console.log(loginResult);
Features
- User registration with validation for email and password formats.
- Login functionality with validation for user credentials.
- Simple API for integrating registration and login functionality into Node.js applications.
License
This project is licensed under the MIT License.