Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@politico/graphics-kit

Package Overview
Dependencies
Maintainers
11
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@politico/graphics-kit

[![npm version](https://badge.fury.io/js/%40politico%2Fgraphics-kit.svg)](https://badge.fury.io/js/%40politico%2Fgraphics-kit)

  • 1.0.1
  • npm
  • Socket score

Version published
Weekly downloads
2
decreased by-66.67%
Maintainers
11
Weekly downloads
 
Created
Source

@politico/graphics-kit

npm version

Install

$ yarn add @politico/graphics-kit

Use

import { BaseChart, d3 } from '@politico/graphics-kit';

class MyChart extends BaseChart {
  defaultProps = {
    stroke: '#ccc',
  }

  defaultData = [60, 40, 20]

  draw() {
    const data = this.data();
    const props = this.props();
    const node = this.selection().node();

    d3.select(node).appendSelect('svg');
    // ...
  }
}

Snippets

Includes Atom snippets to shortcut building your chart.

  • Chart component demonstrates how to use the base chart component.
  • Chart container imports your chart component into a React container component, with resize and higher-level state hooks.

FAQs

Package last updated on 16 Oct 2019

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc