New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

react-graph

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-graph

Render dynamic graphs based on d3 models

latest
Source
npmnpm
Version
0.0.7
Version published
Maintainers
1
Created
Source

React Graph

Render dynamic graphs based on d3 models with Neo4j data format.

NPM JavaScript Style Guide

Live Demo

Dashboard View

node

Installation

npm install react-graph  --save

Usage

import ReactGraph from 'react-graph';

export const Minimalist = (props) => (
 <ReactGraph
   initialState={props.initialState}
   nodes={props.nodes}
   relationships={props.relationships}
   hasTruncatedFields
   hasLegends
   hasInspector
 />
)

Features

  • Compaptible with Neo4j data format.
  • Complete Dashboard(link to demo) to map your data.
  • Info panel that shows nodes and relationships information on hover.
  • Node menu on click.
  • Custom node colors by node label.
  • Custom relationship colors by relationship type.
  • Sticky nodes (drag to stick, single click to unstick).
  • Dynamic graph update.
  • Zoom.

Neo4j data format

{
    "results": [
        {
            "columns": ["user", "entity"],
            "data": [
                {
                    "graph": {
                        "nodes": [
                            {
                                "id": "1",
                                "labels": ["User"],
                                "properties": {
                                    "userId": "jcarva"
                                }
                            },
                            {
                                "id": "8",
                                "labels": ["Project"],
                                "properties": {
                                    "name": "react-graph",
                                    "title": "react-graph",
                                    "description": "Render dynamic graphs based on d3 models with Neo4j data format.",
                                    "url": "https://github.com/jcarva/react-graph",
                                    "mood": "https://youtu.be/dQw4w9WgXcQ"
                                }
                            }
                        ],
                        "relationships": [
                            {
                                "id": "7",
                                "type": "DEVELOPES",
                                "startNode": "1",
                                "endNode": "8",
                                "properties": {
                                    "from": 1470002400000
                                }
                            }
                        ]
                    }
                }
            ]
        }
    ],
    "errors": []
}

Credits

Inspired and helped this awesome project.

Projects

People

License

GPLv3 🄯 jcarva

Keywords

react

FAQs

Package last updated on 28 Apr 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts