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 🙏

© 2024 – Pkg Stats / Ryan Hefner

craydent-class

v0.15.2

Published

Node module implementing addition classes for functionality and to simplify code for maintainability and readability

Downloads

12

Readme

Craydent 0.15.2

by Clark Inada

Craydent is all inclusive utility library. There are several ways to use the library in NodeJS. More detailed documentation on constants can be found at Craydent Properties. More detailed documentation on methods can be found at Craydent Methods

// require with prototypes - this require will add prototypes to extend classes and add two constants ($c, $g) to the global space.
// $g is an alias to global and $c is the constant containing all the utility methods and properties.
require('craydent-class');
$c.logit($c.VERSION);
arr.prototypedMethod(args);
// require no conflict - this require is the fully modular version with no global constants, prototypes, or methods.
var $c = require('craydent-class/noConflict');
$c.logit($c.VERSION);
$c.prototypedMethod(arr, args);
// require global - this require constants and methods in the global space and add prototypes to extend classes.
// $g is an alias to global and $c is the constant containing all the utility methods and properties.
require('craydent-class/global');
logit($c.VERSION);
arr.prototypedMethod(args);

Categories

Constants

| | | | | ----- | ----- | ----- | | CONSOLE_COLORS (Object) |LOCAL_IP (String) |TEMPLATE_TAG_CONFIG (Object) | DEBUG_MODE (Boolean) |MODULES_LOADED (Object) |TEMPLATE_VARS (Array) | ERROR_TYPES (Array) |PUBLIC_IP (String) |VERSION (String) | HTTP_STATUS_TEMPLATE (Object) |RESPONSES (Object) |

Methods

Class


Benchmarker


Info: Class used to measure the run time of code

Return: (IBenchmarker)

Parameters:

None

Overloads:

None


Cursor


Info: Cursor class to facilitate iteration

Return: (ICursor)

Parameters:

  • records: (Array) Array used to create the iterator to iterate each item

Overloads:

Parameters

  • records: (Object) Object used to create the iterator to iterate each property

OrderedList


Info: Collection class that filters out duplicate values and maintains an ordered list

Return: (IOrderedList)

Parameters:

None

Overloads:

Parameters

  • records?: (Array) Array used to create the initial items in the ordered list
  • sorter?: (SortIterator) Function for sorting logic

Queue


Info: Collection class that follows FIFO

Return: (IQueue)

Parameters:

  • records: (Array) Array used to create the iterator to iterate each item

Overloads:

None


ServerManager


Info: Class used to create a new context for HTTP server

Return: (void)

Parameters:

  • request: (HTTPRequest) HTTP request object provided by createServer
  • response: (HTTPResponse) HTTP response object provided by createServer

Overloads:

None


Set


Info: Collection class that filters out duplicate values

Return: (ISet<T, TResult>)

Parameters:

  • records: (Array) Array used to create the iterator to iterate each item

Overloads:

None

Download