report-generator

1.0.5 • Public • Published

report-generator

Build Status Coverage Status

Sauce Test Status

report-generator encapsulates the task of creating simple html reports.

quick example

 
    var reportGenerator = require('report-generator');
 
    var generator new reportGenerator('report.html', ['col1', 'col2'], function (err) {
        assert(err === null);
    });
 
    // write a simple row
    generator.writeRow(['cell1', 'cell2'], function (err) {
        assert(err === null);
    });
    
    // write a row using a cell object, with color support
    var cells = [
        {cellContent: '1', color: "red"},
        {cellContent: '2', color: "red"}
    ];
 
    var row = [cells];
 
    generator.writeRows(row, function (err) {
        assert(err === null);
        done();
    });
 
    generator.closeReport(function(err){
        assert(err === null);
    });
    

Readme

Keywords

Package Sidebar

Install

npm i report-generator

Weekly Downloads

14

Version

1.0.5

License

ISC

Last publish

Collaborators

  • nboyd