npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@artemsharko/csv-to-json-parser

v1.0.0

Published

CSV to JSON parser with uploading result on Google Drive

Downloads

4

Readme

Csv to json parser

Using

Create .env by example .env.example

npm install
npm run parse --sourceFile "" --resultFile ""

Short Description

You need to build a command line tool which allows the user to convert CSV files to JSON.

Topics

  • Core Concept
  • Event Loop
  • Globals
  • Modules
  • Streams
  • Async Operations
  • NPM
  • Network

Requirements

You need to build an npm package for parsing CSV files to JSON by implementing a custom NODE.js transform stream with the following abilities:

  1. Set or automatically detect the separator that is used for parsing (use "auto-detect" by default if no separator provided)
  2. Upload result JSON file to Google Drive disk
  3. Provide errors handling for converting process and incorrect command line arguments.

This application should accept following command line arguments using process.argv:

  1. "sourceFile" - path to the csv file that need to be converted.

  2. "resultFile" - path to the result json file.

  3. "separator" - separator that is used while converting.

An example of running the app with command line arguments:

- node ./src/index.js --sourceFile "source.csv" --resultFile "result.json" --separator ","

- node ./src/index.js --sourceFile "source.csv" --resultFile "result.json" --separator " "

- node ./src/index.js --sourceFile "source.csv" --resultFile "result.json"

Testing

Write a function that generates at least 10 gigabyte CSV file base on the filled in with mock csv file Generate a CSV file and use it as an source file for your tool. When running the parser pay attention to the RAM that is taken by the process.

Publishing

Add version, name, description, and author of the package in package.json. Publish the package you created to the npm registry.

Advanced Requirements

  1. Implement JSON to CSV parser.