ELDEN JS
Getting Started
What is EldenJS?
EldenJS is a lightweight utility library that brings route protection to the frontend and rate limiting to the backend — all in plain JavaScript or TypeScript. It fits right into Next.js, Express, or any Node.js server. On the client, use verifyAccess; on the server, reach for rateControl.
Features
verifyAccess— Secure frontend routes by checking cookies or tokens with your backend. Returns access details you can use to decide whether to grant entry.rateControl— Guard your server with IP-based rate limiting powered by Redis. Provides usage data to help you allow or block requests.- Promise-based API with minimal setup.
- Framework-agnostic and dependency-light.
- ✅ Fully tested with Jest to ensure stability and reliability.
Installation
Using npm:
npm install elden-js
Using yarn:
yarn add elden-js
Using pnpm:
pnpm add elden-js
All utilities in EldenJS are covered by comprehensive Jest tests, so you can use them in production with confidence.