Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
react-graph-viz-engine
Advanced tools
An out-of-the-box React component for visualizing graph data.
Key features:
React component for visualizing graph data.
TLDR - Try the Online Demo!
This project wraps the library in a Storybook UI. More information on Storybook here.
The Storybook provides examples for each of the functionalities this library provides. For each of these examples, you can:
To run the storybook on a local machine, clone the repo. Then:
yarn install
yarn start
A web browser will open with the storybook definitions for the component.
To use this component in your own React app, first install the library:
npm install react-graph-viz-engine
yarn add react-graph-viz-engine
Then, you can include the component anywhere inside your app:
import GraphVisualization from 'react-graph-viz-engine'
import React from "react";
export const App = () => {
return <GraphVisualization
data={...}
graphqlUrl={...}
graphqlQuery={...}
renderer="cytoscape"
layout="graph"
showNavigator={false}
style = {},
interactions = {} />
}
The Storybook contains examples on what to use in the fields of the GraphVisualization component.
This library can be extended with your own graph renderers and customizations.
See src/component/renderer/cytoscape
and src/component/renderer/react-force-graph
for examples.
After cloning this repository, install and run the storybook:
yarn install
yarn start
# yarn build
Each component (src/component/renderer/
) should contain the following five files:
renderer.tsx: The react component that renders the visualization.
formatter.ts: Code responsible for translating the generic data object into a visualization-specific data format.
config.ts: A place for generic config variables for the visualization.
config-mapper.ts: Code responsible for translating the generic configuration object into visualization-specific style config.
style.css: CSS styling to apply to the React component.
Don't forget to extend src/component/graph/Graph.tsx
to include your custom component.
This is an experimental release of the library. If you have any questions, please reach out to the maintainers of this project. Feedback is much appreciated.
FAQs
React component for visualizing graph data
The npm package react-graph-viz-engine receives a total of 6 weekly downloads. As such, react-graph-viz-engine popularity was classified as not popular.
We found that react-graph-viz-engine demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.