Registry / database / iovalkey

iovalkey

JSON →
library0.3.3jsnpmunverified

A robust, performance-focused Valkey/Redis client for Node.js, based on ioredis. Current stable version is 0.3.3. It is a friendly fork of ioredis after a specific commit, supporting Valkey >= 2.6.12 and fully compatible with Valkey 7.x. Key differentiators: full cluster and sentinel support, streams, pipelining, Lua scripting, Valkey Functions, pub/sub, TLS, offline queue, autopipelining, and NAC mapping. Written in TypeScript with bundled type declarations. Release cadence: actively maintained with frequent updates. It provides a drop-in replacement for ioredis with similar API.

npm install iovalkey
INSTALL
IMPORT
SIG · IOVALKEY
I
iovalkey
databasejavascriptv0.3.3
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Valkey
import { Valkey } from 'iovalkey'
const Valkey = require('iovalkey')
Named import is the recommended way in TypeScript projects. CommonJS require works but may cause type issues.
default import of Valkey
import Valkey from 'iovalkey'
import { default as Valkey } from 'iovalkey'
Default import is still supported but will be deprecated in next major version. Use named import instead.
Pipeline
import { Pipeline } from 'iovalkey'
import Pipeline from 'iovalkey'
Pipeline is a named export, not a default export. TypeScript users should use type imports for type assertions.

Basic setup with iovalkey, set/get a key, and pipeline example.

const Valkey = require('iovalkey'); // or import { Valkey } from 'iovalkey' const client = new Valkey(); // connect to localhost:6379 async function quickstart() { await client.set('mykey', 'value'); const val = await client.get('mykey'); console.log(val); // 'value' // pipeline example const pipeline = client.pipeline(); pipeline.set('key1', 'val1'); pipeline.get('key1'); const results = await pipeline.exec(); // [[null, 'OK'], [null, 'val1']] console.log(results); client.disconnect(); } quickstart();
Debug
Known issues
deprecatedDefault import (import Valkey from 'iovalkey') is deprecated and will be removed in the next major version.
fix
Use named import: import { Valkey } from 'iovalkey'
affects: >=0.1.0
breakingiovalkey requires Node.js >= 18.12.0. Older versions are not supported.
fix
Update Node.js to >= 18.12.0
affects: >=0.3.0
gotchaThe package is a fork of ioredis; some ioredis plugins may not be compatible.
fix
Test plugins with iovalkey; consider using native alternatives.
affects: >=0.1.0
Errors
Common errors & fixes
Error: Cannot find module 'iovalkey'
Package not installed or incorrect import path.
fix
Run: npm install iovalkey
TypeError: valkey.get is not a function
Using default import incorrectly in TypeScript (import Valkey from 'iovalkey') which returns a constructor, not an instance.
fix
Use: import { Valkey } from 'iovalkey'; const client = new Valkey();
Upgrade
Version history
0.3.3latest on npm
Audit
Dependencies
ioredisoptionaliovalkey is a fork of ioredis; some internal code and API patterns match ioredis
Agent activity
6 hits · last 30 days
node
6
Resources
iovalkey — npm install iovalkey · libregistry