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

manus-json-processor

v1.0.1

Published

Advanced JSON manipulation and transformation library - Merge, flatten, transform, validate JSON

Readme

Manus JSON Processor

Advanced JSON manipulation and transformation library for Node.js. Merge, flatten, transform, and validate JSON with ease.

Features

  • Deep merge - Recursively merge multiple JSON objects
  • Flatten/Unflatten - Convert nested objects to flat structures and back
  • Path access - Get/set values using dot notation paths
  • Filter & Map - Filter and transform JSON objects
  • Validation - Validate JSON against schemas
  • Sorting - Sort JSON keys recursively
  • Utilities - Clone, omit, pick, and more
  • Zero dependencies - Lightweight and fast

Installation

npm install manus-json-processor

Quick Start

const { JSONProcessor, merge, flatten } = require('manus-json-processor');

// Merge objects
const obj1 = { a: 1, b: 2 };
const obj2 = { c: 3 };
const merged = merge(obj1, obj2);
// { a: 1, b: 2, c: 3 }

// Flatten nested object
const nested = { user: { name: 'John', email: '[email protected]' } };
const flat = flatten(nested);
// { 'user.name': 'John', 'user.email': '[email protected]' }

// Get value by path
const value = JSONProcessor.getByPath(nested, 'user.name');
// 'John'

Advanced Usage

const { JSONProcessor } = require('manus-json-processor');

// Deep merge with multiple objects
const config = JSONProcessor.deepMerge(
  { db: { host: 'localhost' } },
  { db: { port: 5432 } },
  { db: { user: 'admin' } }
);

// Filter JSON
const filtered = JSONProcessor.filter(obj, (key, value) => 
  typeof value === 'string'
);

// Map JSON values
const mapped = JSONProcessor.map(obj, (value) => 
  typeof value === 'string' ? value.toUpperCase() : value
);

// Sort keys recursively
const sorted = JSONProcessor.sortKeys(obj);

// Validate against schema
const schema = { name: 'string', age: 'number' };
const result = JSONProcessor.validate(obj, schema);

API Reference

JSONProcessor Class

clone(obj)

Deep clone JSON object.

merge(...objects)

Merge multiple JSON objects (shallow).

deepMerge(target, ...sources)

Deep merge multiple JSON objects.

filter(obj, predicate)

Filter JSON by predicate function.

map(obj, mapper)

Map JSON values.

flatten(obj, prefix)

Flatten nested JSON object.

unflatten(obj)

Unflatten JSON object.

getByPath(obj, path)

Get value using dot notation path.

setByPath(obj, path, value)

Set value using dot notation path.

omit(obj, keys)

Remove specified keys from object.

pick(obj, keys)

Pick specified keys from object.

sortKeys(obj, recursive)

Sort JSON keys.

validate(obj, schema)

Validate JSON against schema.

getAllKeys(obj)

Get all keys recursively.

Convenience Functions

  • merge(...objects) - Merge objects
  • flatten(obj) - Flatten object
  • unflatten(obj) - Unflatten object

Examples

Configuration Management

const { JSONProcessor } = require('manus-json-processor');

const defaults = { api: { timeout: 5000, retries: 3 } };
const userConfig = { api: { timeout: 10000 } };
const config = JSONProcessor.deepMerge(defaults, userConfig);

Data Transformation

const { flatten } = require('manus-json-processor');

const data = {
  user: { name: 'John', email: '[email protected]' },
  settings: { theme: 'dark', notifications: true }
};

const flat = flatten(data);
// Send to CSV or database

API Response Processing

const { JSONProcessor } = require('manus-json-processor');

const response = { data: { users: [...], meta: { total: 100 } } };
const users = JSONProcessor.getByPath(response, 'data.users');
const total = JSONProcessor.getByPath(response, 'data.meta.total');

Performance

  • Handles deeply nested objects efficiently
  • Optimized for large JSON structures
  • Zero dependencies
  • Fast transformation operations

License

MIT License

Support

For issues and questions: https://github.com/kokashinobi/manus-ai-tools/issues


Made with ❤️ by Manus AI