Miss any of our Open RFC calls?Watch the recordings here! »

This package has been deprecated

Author message:

WARNING: This project has been renamed to 'react-json-csv'.

react-json-excel

1.1.0 • Public • Published

React Json Excel

A React library to render a component that helps in json to excel conversion.

npm version dependencies Status badge devDependency Status badge Gitter badge

Install

Install the component using NPM:

$ npm install --save react-json-excel

Usage

Initialise module

import {
  JsonToExcel
} from 'react-json-excel';

Render

Json To Excel

Converts json to excel file (.csv format) and downloads it

const className = 'class-name-for-style',
  filename = 'Excel-file',
  fields = {
    "index": "Index",
    "guid": "GUID"
  },
  style = {
    padding: "5px"
  },
  data = [
    { index: 0, guid: 'asdf231234'},
    { index: 1, guid: 'wetr2343af'}
  ],
  text = "Convert Json to Excel";
<JsonToExcel
  data={data}
  className={className}
  filename={filename}
  fields={fields}
  style={style}
  text={text}
/>

License

MIT License

Install

npm i react-json-excel

DownloadsWeekly Downloads

360

Version

1.1.0

License

MIT

Unpacked Size

56 kB

Total Files

11

Last publish

Collaborators

  • avatar