Systemix is a modular, high-performance toolkit designed for building secure and scalable JavaScript and TypeScript systems.
翻譯準備中
取自儲存庫 README
正在載入完整 README。
檢視完整 README ↗Systemix is a modular, high-performance toolkit for building secure and scalable JavaScript and TypeScript systems. It provides typed env loading, cryptographically secure password, passphrase, and token generators, plus shareable ESLint, TypeScript, and test runner configs — a lightweight "standard library" for modern Node.js and web projects.
Published to npm and GitHub Packages:
Links: npm org · npm profile
pnpm add @systemix/env @systemix/password @systemix/passphrase @systemix/token @systemix/hash @systemix/cipher @systemix/id @systemix/rate-limit
import { load } from '@systemix/env';
import { generatePassword } from '@systemix/password';
import { generatePassphrase } from '@systemix/passphrase';
import { generateToken } from '@systemix/token';
import { hashPassword, verifyPassword } from '@systemix/hash';
import {
encryptString,
decryptString,
generateKeyBytes,
} from '@systemix/cipher';
import { generateId } from '@systemix/id';
import { createRateLimiter } from '@systemix/rate-limit';
// Typed env vars
const env = load({ PORT: { type: 'number', default: 3000 } });
// Secure random password
console.log(generatePassword({ length: 16, useSymbols: true }));
// → "Z#kM@4p*J!h2X&b7"
// Memorable passphrase
console.log(generatePassphrase({ wordCount: 4 }));
// → "apple orange banana kiwi"
// API key / session token
console.log(generateToken({ byteLength: 32, charset: 'hex' }));
// → "a1b2c3d4e5f6..."
// Hash and verify a password
const encoded = await hashPassword('hunter2');
await verifyPassword('hunter2', encoded); // → true
// Authenticated encryption
const key = generateKeyBytes();
const ciphertext = await encryptString('sensitive data', key);
await decryptString(ciphertext, key); // → "sensitive data"
// Non-secret IDs
console.log(generateId()); // → "V1StGXR8_Z5jdHi6B-myT"
// Rate limiting
const limiter = createRateLimiter({ limit: 100, windowMs: 60_000 });
limiter.limit('user:42'); // → { success: true, remaining: 99, ... }
| Package | Description |
|---|---|
@systemix/env · npm | Typed environment variable loading and validation with .env file support. |
@systemix/password · npm | Cryptographically secure password generator with character guarantees and entropy tools. |
@systemix/passphrase · npm | Human-readable passphrase generator with formatting and entropy tools. |
@systemix/token · npm | Secure token generator (hex, base64, base64url) and signed-token module. |
@systemix/hash · npm | Argon2id password hashing in PHC format, with scrypt and PBKDF2. |
@systemix/cipher · npm |
# Utilities (env, password, passphrase, token, hash, cipher, id, rate-limit)
pnpm add @systemix/env @systemix/password @systemix/passphrase @systemix/token @systemix/hash @systemix/cipher @systemix/id @systemix/rate-limit
# Configs (ESLint flat config, TypeScript tsconfig, test runner)
pnpm add -D @systemix/eslint @systemix/typescript @systemix/runner
With npm:
npm install @systemix/env @systemix/password @systemix/passphrase @systemix/token @systemix/hash @systemix/cipher @systemix/id @systemix/rate-limit
npm install -D @systemix/eslint @systemix/typescript @systemix/runner
From GitHub Packages (add to .npmrc: @shahadathhs:registry=https://npm.pkg.github.com):
pnpm add @shahadathhs/env @shahadathhs/password @shahadathhs/passphrase @shahadathhs/token @shahadathhs/hash @shahadathhs/cipher @shahadathhs/id @shahadathhs/rate-limit
pnpm add -D @shahadathhs/eslint @shahadathhs/typescript @shahadathhs/runner
Recommendation: Use npm (
@systemix/*) — no extra config.
In an era where security and performance are paramount, Systemix aims to provide developers with a "standard library" of tools that are:
crypto for high-entropy randomization.We welcome contributions! Whether it's reporting a bug, suggesting a feature, or submitting a pull request, your help is appreciated.
git clone https://github.com/shahadathhs/systemix.gitpnpm installpnpm buildpnpm ci:checkDistributed under the MIT License. See LICENSE for more information.
| Authenticated AES-256-GCM encryption and decryption for data at rest. |
@systemix/id · npm | UUIDv7, UUID v4, ULID, and nanoid-style IDs, crypto-grade randomness. |
@systemix/rate-limit · npm | Fixed-window, sliding-window, and token-bucket rate limiting with Express middleware. |
@systemix/eslint · npm | ESLint v10 flat configs for JS, TS, React, Express, and Next.js. |
@systemix/typescript · npm | Base TypeScript configs for various environments. |
@systemix/runner · npm | Minimal test runner with assert, assertThrows, createRunner, runSuites. |