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

@generatedpixel/gp-analytics

v1.1.2

Published

Foundational metadata models for tables, fields, joins, and localized values

Readme

gp-analytics

Foundational metadata models for analytics applications: groups, tables, field groupings, fields, relationships, and localized values.

Overview

gp-analytics contains metadata models and Angular components and services for datasets, reporting, and dashboards. It is developed as a separate package in the gp-ui monorepo.

Features

  • Table metadata: Group tables and their field groupings under a named grouping.
  • Field capabilities: Describe whether a field is reportable, filterable, sortable, groupable, indexed, or usable for joins.
  • Relationships: Model one-to-one and one-to-many joins by source and target field IDs.
  • Localized values: Keep a stable stored value separate from language-specific display values.

Installation

npm install gp-analytics

Theming

gp-analytics components read colors, surfaces, and radii from the same --gp-* custom properties published by @generatedpixel/gp-ui-theme, so switching a theme or toggling dark mode automatically restyles every analytics component alongside the rest of gp-ui.

On top of that, it publishes its own --gp-analytics-* token layer (widget surfaces, code blocks, up/down metric colors, chart palette, designer/inspector chrome) for anything analytics-specific that isn't part of the core design system. Each token falls back to a --gp-* theme token, so it stays in sync with the active theme unless you override it.

Import the token stylesheet once alongside the core theme CSS:

@import '@generatedpixel/gp-ui-theme/src/index.css';
@import '@generatedpixel/gp-analytics/src/lib/styles/analytics-theme-tokens.scss';

Override any analytics-only token per-app, e.g. to give KPI cards a custom accent:

:root {
  --gp-analytics-chart-1: #22c55e;
  --gp-analytics-widget-radius: 1rem;
}

Quick Start

Define metadata

import { Grouping } from 'gp-analytics';

const commerce: Grouping = {
  groupingId: 'commerce',
  groupingName: 'Commerce',
  tables: []
};

Scripts

Run these commands from the gp-ui repository root:

  • npm run build:analytics - Builds gp-ui, gp-grid, and then gp-analytics to dist/packages/gp-analytics.
  • npm run test:analytics - Runs the analytics Vitest unit tests.
  • npm run build / npm test - Builds or tests the complete monorepo, including analytics.

Every gp-analytics component has its own standalone demo page under apps/gp-ui-demo (see the "Analytics" section of the sidebar), so each component can be explored in isolation with a live demo and a full properties/events reference. The original standalone gp-analytics demo app has been fully superseded by this integration; its history remains accessible via git log --full-history -- packages/gp-analytics.