
Security News
Meet Socket at Black Hat and DEF CON 2025 in Las Vegas
Meet Socket at Black Hat & DEF CON 2025 for 1:1s, insider security talks at Allegiant Stadium, and a private dinner with top minds in software supply chain security.
json2csv-export
Advanced tools
A simplest javascript library that help you generate csv file and export
npm install json2csv-export --save
or
yarn add json2csv-export
or use cdn bellow before end of body tag
<script src="https://unpkg.com/json2csv-export@1.0.5/index.js"></script>
import { exportCsv } from "json2csv-export";
const yourCustomFunction = () => {
const header = {
name: "Fullname",
age: "Age",
designation: "Designation",
role: "Profession",
education: "Study",
hometown: "Current City",
email: "Email Address",
post: "Total Post",
};
const data = [
{
name: "Shahan Chowdhury",
age: "26",
designation: "Mr.",
role: "Software Engineer",
education: "Computer Science and Engineering",
hometown: "Sylhet",
email: "shahan@test.com",
post: 27,
},
{
name: "Rayhan Chowdhury",
age: "31",
designation: "Mr.",
role: "Test Engineer",
education: "CS",
hometown: "Sylhet",
email: "rayhan@test.com",
post: 25,
},
];
exportCsv({
header, // header is optional. If you don't pass header, it will take keys from data
data,
filename: 'yourfilename' // the file will downloaded yourfilename.csv
});
};
`
Support me by giving star
FAQs
A javascript library to convert json array into csv
The npm package json2csv-export receives a total of 35 weekly downloads. As such, json2csv-export popularity was classified as not popular.
We found that json2csv-export 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.
Security News
Meet Socket at Black Hat & DEF CON 2025 for 1:1s, insider security talks at Allegiant Stadium, and a private dinner with top minds in software supply chain security.
Security News
CAI is a new open source AI framework that automates penetration testing tasks like scanning and exploitation up to 3,600× faster than humans.
Security News
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.