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

@datarailsshared/dr_renderer

v1.5.174

Published

DataRails charts and tables renderer

Readme

Datarails renderer

This project was generated by amazing Datarails R&D team

Install

npm i @datarailsshared/dr_renderer

Usage

const dr_renderer = require( "@datarailsshared/dr_renderer");
dr_renderer.init($, window, window.document);
let default_colors = ["#106bd0", "#00cee8", "#95c8d8", "#89cff0", "#FE746D", "#6ADC4C", "#9B9AD9", "#ff8000", "#C11B12", "#5a41f9"];
let hr = dr_renderer.getInitHighchartsRenderer($, document, default_colors, Highcharts);

Development

Types

To compile types for the project use: npm run build:types

Publish to npm

Just merge to master branch

Error Handling

The renderer includes a comprehensive error handling system with specific error types for different scenarios:

Error Codes

The following error codes are available via RendererErrorCodes:

  • NoDataError (1) - No data is available for rendering
  • TooMuchDataError (3) - Dataset exceeds capacity
  • DataConflictError (5) - Conflicts detected in data being processed
  • GaugeConfigurationError (6) - Gauge chart missing required data
  • GenericRenderingError (7) - Generic rendering failure in PivotTable components
  • GenericComputationalError (8) - Generic computational failure in PivotTable components

Error Classes

All errors extend the BaseRendererError class which includes:

  • code - Unique error code for identification
  • title - Human-readable error message
  • options - Additional context or configuration

Usage Example

const { RendererErrorCodes, NoDataError, TooMuchDataError } = require('@datarailsshared/dr_renderer');

try {
    // Your rendering code here
} catch (error) {
    if (error instanceof NoDataError) {
        console.log('No data available:', error.title);
    } else if (error.code === RendererErrorCodes.TooMuchDataError) {
        console.log('Too much data:', error.title);
    }
}