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

reportjs

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

reportjs

Report Library

  • 2.0.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

Report.js

Build Status

Dependancies

Report.js depend on jQuery and Chart.js. Don't forget to add them to your page.

Usage

import {Renderer} from 'reportjs';

let renderer = new Renderer(),
    options = {
        data: {
            dimensions: [{ id: 'Measures'}, { id: 'Year' }],
            dimensionValues: [
                [{ id: 'count', caption: 'My Count' }, { id: 'sum', caption: 'My Sum' }],
                [{ id: '2013' }, { id: '2014' }]
            ],
            cells: [
                {value: 10, dimensionValues: [0, 0]},
                {value: 20, dimensionValues: [1, 1]},
                {value: 15, dimensionValues: [0, 1]}
            ]
        },
        layout: {
            type: 'table',
            rows: ['Measures'],
            columns: ['Measures', 'Category']
        }
    };

renderer.renderTo($('#mydiv'), options);

This will output

20132014
My Count10
My Sum1520

For a browser example without ES6, check the demo

Contribute

Install the dependencies

git clone https://github.com/youknowriad/report.js.git && cd report.js
npm install
bower install

Tests

npm test

FAQs

Package last updated on 28 Nov 2014

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