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 🙏

© 2026 – Pkg Stats / Ryan Hefner

hyperdbx.js

v1.0.0

Published

High-performance database library with file-based storage supporting key-value and document operations

Readme

HyperDBX.js

🌟 Why Choose HyperDBX.js?

HyperDBX.js isn't just another database library - it's an integrated solution combining ease of use, flexibility, and high performance. Designed specifically for Node.js developers who need a reliable data storage solution without the complexity of traditional database setups.

✨ What Sets Us Apart

| Feature | HyperDBX.js | LowDB | NeDB | SQLite | MongoDB | |---------|------------|-------|------|--------|---------| | Ease of Use | ⭐⭐⭐⭐⭐ | ⭐⭐⭐⭐ | ⭐⭐⭐ | ⭐⭐ | ⭐⭐ | | Key-Value Storage | ✅ | ✅ | ❌ | ❌ | ✅ | | Document Storage | ✅ | ✅ | ✅ | ❌ | ✅ | | Memory Caching | ✅ | ❌ | ✅ | ❌ | ✅ | | Built-in Encryption | ✅ | ❌ | ❌ | ❌ | ❌ | | Authentication (JWT) | ✅ | ❌ | ❌ | ❌ | ✅ | | Real-time Sync | ✅ | ❌ | ❌ | ❌ | ✅ | | Cloud Sync | ✅ | ❌ | ❌ | ❌ | ✅ | | No Heavy Dependencies | ✅ | ✅ | ✅ | ❌ | ❌ | | Package Size | Small | Small | Medium | Large | Very Large |

📦 Installation

npm install hyperdbx.js

🚀 Quick Start

Basic Usage

const HyperDB = require('hyperdbx.js');

// Create a new database
const db = new HyperDB({ 
  storage: 'filestore',
  path: './my-database'
}); 

// Using the key-value interface
async function basicExample() {
  // Store data
  await db.set('user:1001', { 
    name: 'John', 
    email: '[email protected]',
    role: 'admin'
  });
  
  // Retrieve data
  const user = await db.get('user:1001');
  console.log(user);
  
  // Check if a key exists
  const exists = await db.has('user:1001');
  console.log('User exists:', exists);
  
  // Delete data
  await db.delete('user:1001');
}

basicExample().catch(console.error);

Using Document Collections

const HyperDB = require('hyperdbx.js');
const db = new HyperDB({ storage: 'filestore', path: './my-database' });

async function collectionsExample() {
  // Create a collection for products
  await db.createCollection('products');
  
  // Add products
  await db.insert('products', { 
    id: 'prod-1', 
    name: 'Smartphone', 
    price: 999, 
    inStock: true
  });
  
  await db.insert('products', { 
    id: 'prod-2', 
    name: 'Laptop', 
    price: 1499, 
    inStock: true
  });
  
  // Find a specific product
  const laptop = await db.findOne('products', { name: 'Laptop' });
  console.log('Laptop details:', laptop);
  
  // Find all available products
  const availableProducts = await db.find('products', { inStock: true });
  console.log('Available products:', availableProducts.length);
  
  // Update product price
  await db.update('products', { id: 'prod-1' }, { price: 899 });
  
  // Delete a product
  await db.deleteFrom('products', { id: 'prod-2' });
}

collectionsExample().catch(console.error);

📋 Key Features

🔐 Security & Encryption

HyperDBX.js provides strong encryption for sensitive data:

const db = new HyperDB({
  storage: 'filestore',
  path: './secure-database',
  security: {
    encryption: {
      enabled: true,
      secret: 'your-secure-encryption-key'
    },
    jwt: {
      enabled: true,
      secret: 'your-jwt-secret-key'
    }
  }
});

// Data is automatically encrypted
await db.set('api_credentials', {
  api_key: 'sensitive-api-key',
  api_secret: 'very-sensitive-secret'
});

// Create and verify JWT tokens
const token = db.security.generateToken({ userId: 1, role: 'admin' });
const verified = db.security.verifyToken(token);

🔄 Real-time Synchronization

Set up real-time synchronization between multiple clients:

const db = new HyperDB({
  storage: 'filestore',
  path: './sync-database',
  realtime: {
    enabled: true,
    serverUrl: 'wss://your-websocket-server.com'
  }
});

// Listen for data changes
db.on('sync', (change) => {
  console.log('Received new change:', change);
});

☁️ Cloud Synchronization

Support for synchronizing data with cloud services:

const db = new HyperDB({
  storage: 'filestore',
  path: './cloud-database',
  sync: {
    enabled: true,
    type: 'firebase',
    config: {
      // Firebase or other cloud service settings
      apiKey: 'your-api-key',
      databaseURL: 'https://your-database.firebaseio.com'
    }
  }
});

🧩 Architecture

HyperDBX.js is designed with a modular architecture for easy extensibility:

HyperDBX.js/
├── src/
│   ├── adapters/         # Storage engines
│   ├── storage-engine.js # Core storage engine
│   ├── memory-cache.js   # In-memory caching system
│   ├── security.js       # Encryption and security module
│   ├── cloud-sync.js     # Cloud synchronization
│   ├── realtime-sync.js  # Real-time synchronization
│   └── utils.js          # Helper functions
├── index.js              # Main library interface
└── examples/             # Example implementations

📊 Optimal Performance

HyperDBX.js is optimized for excellent performance. The in-memory caching mechanism accelerates repeated read operations, while organized file storage ensures efficient write operations.

Speed Comparison (Operations per Second)

| Operation | HyperDBX.js | LowDB | NeDB | |-----------|------------|-------|------| | Read | ~10,000 | ~5,000| ~7,000| | Write | ~2,000 | ~1,000| ~1,500| | Search | ~5,000 | ~2,000| ~3,000|

🔧 Advanced Options

Cache Customization

const db = new HyperDB({
  storage: 'filestore',
  path: './database',
  cache: {
    enabled: true,
    maxSize: 5000,      // Maximum number of items in memory
    ttl: 60 * 60 * 1000 // Expiration time: 1 hour
  }
});

Advanced Queries

// Advanced queries (coming in future versions)
const expensiveProducts = await db.find('products', {
  price: { $gt: 1000 },
  category: { $in: ['electronics', 'computers'] },
  'specs.ram': { $gte: 16 }
});

📚 Comprehensive Examples

The library includes a set of detailed examples in the examples/ folder:

🗺️ Roadmap

We're continuously working to improve HyperDBX.js. Upcoming features include:

  • More advanced query support ($gt, $lt, $in, etc.)
  • Indexes for faster search operations
  • Storage engine performance improvements
  • Batch operations support
  • Hierarchical data support
  • Cloud synchronization enhancements

For more details, please check the Roadmap.

🤝 Contributing

Contributions from the community are welcome! If you'd like to contribute:

  1. Fork the project
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

👥 Development Team

HyperDBX.js was developed by GhostNet Studio, a team of passionate developers creating easy-to-use, high-performance open-source tools.

📄 License

This project is licensed under the MIT License, which means you can freely use it in both personal and commercial projects.

📞 Support

If you encounter any issues or have questions, please open an issue on GitHub or contact us at:

  • Discord: https://discord.gg/HVbWnCZr7s