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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@cosmograph/cosmograph

v2.0.0

Published

Cosmograph: The fastest web-based graph visualization library

Readme

npm version license GitHub Issues Discord Docs

A powerful JavaScript graph visualization library powered by Cosmos.gl – a GPU-accelerated force layout engine. It rapidly visualizes large scale network graphs and machine learning embeddings in any modern web browser, providing interactive tools for exploring your data.

✨ Features

  • Easily process millions of points and edges on modern hardware
  • Ready-to-use interactive components: timeline, histograms and legends
  • Handy features like clustering, labels, dragging points and area selection
  • Rich configuration API for full customization over graph behavior and appearance
  • Support for standard data formats including .csv, .parquet, .arrow and .json
  • SQL capabilities for powerful data transformations and filtering
  • Connect directly to your tables in external DuckDB instances
  • TypeScript support featuring comprehensive types and API hints

🚀 Quick Start

Install the package:

npm install @cosmograph/cosmograph@beta

Get the data, configure the graph and render Cosmograph in the provided container:

import { Cosmograph, prepareCosmographData } from '@cosmograph/cosmograph'

// Points and links data can be:
// - Array of objects
// - File (.csv/.tsv, .parquet/.pq, .arrow, .json)
// - URL string to a file
// - Apache Arrow Table (binary data Uint8Array/ArrayBuffer)
// - DuckDB table name if connection is passed into the Cosmograph constructor

const rawPoints = [{ id: 'a' }, { id: 'b' }, { id: 'c' }]

const rawLinks = [
  { source: 'a', target: 'b' },
  { source: 'b', target: 'c' },
  { source: 'c', target: 'a' },
]

// Create a config to map your data into Cosmograph's internal format
const dataConfig = {
  points: {
    pointIdBy: 'id',
  },
  links: {
    linkSourceBy: 'source',
    linkTargetsBy: ['target'],
  },
}

const createCosmograph = async (container: HTMLElement): Promise<void> => {
  // Prepare data and config for Cosmograph
  const result = await prepareCosmographData(dataConfig, rawPoints, rawLinks)

  // Create Cosmograph instance from prepared data and config
  if (result) {
    const { points, links, cosmographConfig } = result
    const cosmograph = new Cosmograph(container, { points, links, ...cosmographConfig })
  }
}

// Render Cosmograph in the provided container
createCosmograph(document.getElementById('cosmograph-container'))

Check out the Cosmograph documentation for more information and examples.

🛸 Issues and Contributing

While currently closed source, we welcome your feedback! Help improve Cosmograph by submitting bug reports and feature ideas in our issues repository.

💫 License

Cosmograph is licensed under the CC-BY-NC-4.0 license and free for any non-commercial usage. If you want to use it in a commercial project, please reach out to us.

🌌 Cosmograph Universe

@cosmograph/react - Cosmograph for React applications
@cosmos.gl/graph - Cosmos.gl graph-rendering engine
py_cosmograph - Jupyter widget for data science workflows in Python

👩🏻‍🚀 Contacts

🌎 cosmograph.app
📩 [email protected]
👾 Cosmograph Discord channel