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

cubitt-graph

v1.0.2

Published

Cubitt in-memory graph with subgraphs and connectors

Downloads

12

Readme

Cubitt Graph

Typescript Graph library for the Cubitt framework.

npm version GitHub license Build Status Test Coverage

About

This package contains an in-memory graph with connectors. All Elements have support for dynamic properties. The graph has the following elements:

  • Model A subgraph inside the graph. All Nodes and Edges have to be linked to a Model.
  • Node A traditional Node.
  • Connector A Connector is an element that is connected to a Node, to which edges can be connected. A Node can have many connectors. A Connector can have many edges.
  • Edge An traditional directed edge that can be connected to connectors. It is not possible to connect an Edge directly to a Node.

It's main use case will be for the Cubitt framework, but the graph can be used standalone if it fits your datamodel.

Installation

$ npm install cubitt-graph

Features

  • Intergraph links
  • Hierarchical graphs
  • Connector support
  • Properties support on all Elements
  • Typescript
  • Unit tested

Usage

The Project class (implements GraphInterface) is the main entrypoint for consumers of this package. It is as simple as:

var graph = new Project();

All available methods on this class are described in the Code documentation.

Documentation

For developers

To generate documentation run:

$ npm install --only=dev
$ node_modules/.bin/typedoc --out doc/ --module commonjs --exclude test --readme README.md --target ES5 --mode file src/

To run the tests:

$ npm install --only=dev
$ cd node_modules/cubitt-graph
$ mocha

To debug the tests (uses node-debug, uses Chrome debugging tools):

  1. First set sourceMaps to true in src/tsdconfig.json (ensures that you can debug the Typescript code instead of the generated JavaScript)
$ npm install --only=dev
$ node-debug _mocha --no-timeouts

People

The original authors of Cubitt are Sander Klock and Thomas Ipskamp. The project is coordinated by Jan Martijn van der Werf.

License

MIT