Having actually written something like this before --- and it remains on my machine as an executable of only a few kilobytes --- I'm curious about the thought process that could lead to someone uploading a considerable volume of potentially sensitive CSV data to this site, and then downloading a proportionally larger amount of JSON from it. The site doesn't even appear to support HTTPS.
Technically, all the file processing can happen client-side now, thanks to the HTMl5 file API. Users' data doesn't have to leave the browser. [shameless plug] This is the approach I have taken creating a similar converter (which also works offline): http://mango-is.com/tools/csv-to-json/
CSVJSON – Self Rise of an Online Tool
21–30 of 36 posts
Re: CSVJSON – Self Rise of an Online Tool
#22FYI: The term I search for when needing something along these lines is "JSON prettify"
Re: CSVJSON – Self Rise of an Online Tool
#23from 15000 quality page views you should expect at least $15 of revenue ($1 CPM) even higher numbers from developers (valuable users). Check out something like https://carbonads.net/ and it might at least pay for your hosting. It's invite only though, so you might have to ask for an invitation.
This being said, I will consider trying carbonads. Thanks for the tip.
Re: CSVJSON – Self Rise of an Online Tool
#24Earlier quoted context omitted.
> BTW, does anyone know of a tool to do the reverse? I created a java/scala library[1] (source is scala, but there's a jar with dependencies for java) a few years ago for an Android app I was hired to work on that converts nested JSON to CSV. I was allowed to open source the library later on and released it under the MIT License, so anyone can use it now. Never thought anyone else would ever need to convert json to c…
Yes. Use the built-in JSON.parse() to get the data into memory, then use my jquery-csv library's $.csv.fromArrays() to format the data as CSV. Guess I found a good candidate for a blog post. It's amazing How much I see others struggle with such a aimple concept.
Re: CSVJSON – Self Rise of an Online Tool
#25Earlier quoted context omitted.
Technically, all the file processing can happen client-side now, thanks to the HTMl5 file API. Users' data doesn't have to leave the browser. [shameless plug] This is the approach I have taken creating a similar converter (which also works offline): http://mango-is.com/tools/csv-to-json/
Yes, that is a good idea. However I chose to upload it in order to allow sharing the conversion via a unique generated URL.
Re: CSVJSON – Self Rise of an Online Tool
#26Earlier quoted context omitted.
Yes. Use the built-in JSON.parse() to get the data into memory, then use my jquery-csv library's $.csv.fromArrays() to format the data as CSV. Guess I found a good candidate for a blog post. It's amazing How much I see others struggle with such a aimple concept.
Not sure if you parsed my comment incorrectly or you meant to reply to someone else :)
Either way, why do 2 data format transforms as one lib? It makes more sense to parse JSON into memory in one step then format it as CSV in a separate step.
Ie, what about the 'Single Responsibility Principle'?
Re: CSVJSON – Self Rise of an Online Tool
#27Thanks, I've used your tool a few times and it works beautifully. Quite interesting article too from the SEO pov. BTW, does anyone know of a tool to do the reverse? I have some json files with deeply nested arrays and would like to output a csv file with one line for each "leaf". I can write it myself but would be happy to use an existing tool.
One that I wrote a while ago, which might or might not do what you want: https://github.com/jsnell/json-to-multicsv Note that the mapping from nested / hierarchical JSON file to CSV file(s) is not as obvious as it is the other way around. There's some configuration involved. I wrote a blog post about that particular aspect: https://www.snellman.net/blog/archive/2016-01-12-json-to-mul...
Re: CSVJSON – Self Rise of an Online Tool
#28Thanks, I've used your tool a few times and it works beautifully. Quite interesting article too from the SEO pov. BTW, does anyone know of a tool to do the reverse? I have some json files with deeply nested arrays and would like to output a csv file with one line for each "leaf". I can write it myself but would be happy to use an existing tool.
> BTW, does anyone know of a tool to do the reverse? I created a java/scala library[1] (source is scala, but there's a jar with dependencies for java) a few years ago for an Android app I was hired to work on that converts nested JSON to CSV. I was allowed to open source the library later on and released it under the MIT License, so anyone can use it now. Never thought anyone else would ever need to convert json to c…
Re: CSVJSON – Self Rise of an Online Tool
#29Thanks, I've used your tool a few times and it works beautifully. Quite interesting article too from the SEO pov. BTW, does anyone know of a tool to do the reverse? I have some json files with deeply nested arrays and would like to output a csv file with one line for each "leaf". I can write it myself but would be happy to use an existing tool.
jq ( https://stedolan.github.io/jq/ ) is a great tool for general JSON manipulation. It includes a CSV export filter, so you can run commands like: jq -r '. | map(.key), map(.value) | @csv' which will output a JSON array as CSV.
Re: CSVJSON – Self Rise of an Online Tool
#30You don't rank on beutifier, I've searched lots of times and have never ever seen you, I wish I did