Registry / http-networking / craydent-utility

craydent-utility

JSON →
library1.0.2jsnpmunverified

Craydent is an all-inclusive Node.js utility library providing over 100+ methods and constants for common tasks like AJAX, file system operations, GUID generation, MD5 hashing, path manipulation, and object/array extensions. Version 1.0.2 is the latest stable release. It offers three import modes: prototype-extending (default), no-conflict modular, and global. Ships TypeScript types. Differentiators include prototype augmentation, global constants, and built-in AJAX support.

npm install craydent-utility
INSTALL
IMPORT
SIG · CRAYDENT-UTILITY
C
craydent-utility
http-networkingjavascriptv1.0.2
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.

$c (default require)
const $c = require('craydent-utility/noConflict'); $c.logit('test');
const $c = require('craydent-utility'); $c.logit('test');
The default require adds prototypes and global constants ($c, $g). Use 'noConflict' subpath to avoid global pollution.
global constants and prototypes
require('craydent-utility'); console.log($c.VERSION); arr.prototypedMethod(args);
import { VERSION } from 'craydent-utility';
Default require adds $c and $g to global scope and extends native prototypes. ESM imports are not supported directly.
global-only mode
require('craydent-utility/global'); logit($c.VERSION);
const $c = require('craydent-utility/global'); $c.logit($c.VERSION);
The 'global' subpath adds methods/constants to global scope without exposing a module object.

Demonstrates no-conflict require, AJAX call, GUID generation, MD5 hashing, and recursive mkdir.

// Using no-conflict mode (recommended) const $c = require('craydent-utility/noConflict'); // Example: AJAX call $c.ajax('https://api.example.com/data', 'json') .then(data => console.log('Data:', data)) .catch(err => console.error('Error:', err)); // Example: Generate GUID const guid = $c.guid(); console.log('GUID:', guid); // Example: MD5 hash const hash = $c.md5('hello world'); console.log('MD5:', hash); // Example: Create directory recursively $c.mkdir('/tmp/a/b/c', { recursive: true });
Debug
Known issues
gotchaDefault require adds $c and $g to global scope and extends native prototypes (Array, String, etc.). This can cause conflicts with other libraries.
fix
Use require('craydent-utility/noConflict') instead to avoid global pollution and prototype modifications.
affects: >=1.0.0
gotchaThe library does not support ES module (ESM) imports. Attempting import will fail.
fix
Use CommonJS require() instead of import.
affects: >=1.0.0
gotchaMethods like zipit() return string paths; not promises. Asynchronous behavior may not be obvious.
fix
Check documentation for return types; use callbacks or promises as indicated.
affects: >=1.0.0
gotchaSome methods (e.g., _catchAll) are global and cannot be imported selectively; they must be required from the root.
fix
Only use the default require when you need global exception handlers.
affects: >=1.0.0
Errors
Common errors & fixes
ReferenceError: $c is not defined
Used $c without requiring the default mode that sets global $c.
fix
Use require('craydent-utility') before accessing $c, or use require('craydent-utility/noConflict') and assign to a local variable.
TypeError: arr.prototypedMethod is not a function
Prototypes not extended because no-conflict mode was used.
fix
Use require('craydent-utility') (default) to extend prototypes, or call the static version: $c.prototypedMethod(arr, args).
Cannot find module 'craydent-utility/noConflict'
Older version of craydent-utility that doesn't support the noConflict subpath.
fix
Upgrade to version 1.0.0 or later.
Upgrade
Version history
1.0.2latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
20 hits · last 30 days
node
18
OpenAI (training)
1
Resources
craydent-utility — npm install craydent-utility · libregistry