

REPL: To JSON what Excel is to CSV - spolu
http://repl.cc

======
bru
That's a stupid name... REPL has had a precise meaning (Read-Eval-Print-Loop)
for the last 50 years, and I don't know how one can choose to give that name
to a project.

~~~
vdm
Its a template for building a pipeline. Naming it after this metaphor
("jspipe"?) might work better. It's more like a OpenRefine[0] than Excel; that
analogy doesn't work at all for me.

It's a REPL in the sense that when you click Run, the value of the current
evaluation is used (Looped) as the input for the next expression, but this
stretches the common understanding, and naming it this way fails to
communicate.

The full page transition when you click Run loses the implicit history from a
teletype or terminal scrollback. A shell works because you can see two or more
values were visible at the same time. The second pane could then show the code
of the currently selected value. You could even show the diff/patch between
the values as well.

The 'Run' text should look like a button rather than a label, and be moved to
the right. It might work even better to just evaluate the code on a timeout
without an explicit gesture.

0\. [http://openrefine.org/](http://openrefine.org/)

Edited: for more positive feedback.

~~~
mkl
Yes, it's _a_ repl, sort of, but calling it "repl" is like calling a new text
editor "editor" or a new programming language "language", seriously confusing
and impossible to search for.

~~~
zem
they should have called it "rep" and put up a rant proclaiming "REP IS THE ONE
TRUE REPL"

------
micheljansen
Pretty clever, but pretty obscure compared to Excel.

The power of Excel is that you can manipulate the data within the view itself,
so for that comparison to make sense, I would expect to be able to add a node
to the data, for example, and define its contents using a formula (function).

~~~
cousin_it
Yeah, I don't understand the comparison to Excel either.

What I really want is SQL for JSON. Regular SQL is a declarative language for
transforming flat lists of records into other flat lists of records, and the
challenge is extending it to allow nested records. Has that been done?

~~~
_delirium
It doesn't have very SQLish syntax, but there are various JSON ports of XPath
and XQuery from the XML world.

~~~
cousin_it
Ooh, that's exactly what I was looking for. Thanks!

------
n1cked
Maybe explain on the main page a bit better? I didn't understand what this was
at first and the screenshots for the example didn't really help. I had to play
with it for a minute before I got it.

~~~
snorkel
I played with it too, and I still don't get it. I completely missed the Excel
comparison.

------
northisup
[http://stedolan.github.io/jq/](http://stedolan.github.io/jq/)

~~~
meowface
jq is cool, but can it also be used to construct JSON? It's great for parsing,
but OP's tool covers all the different aspects.

~~~
dontdieych
Yes, It can.

------
fulafel
Do you mean Excel the expensive PC program found on legacy corporate Windows
intranets, or Excel the hard to decipher proprietary file format?

~~~
TeMPOraL
He probably means Excel the industry standard program for data collection,
management and analysis for everyone not working in IT.

~~~
baldfat
And therefore doing it in a way that is NOT reproducible, easy to audit nor
reliable.

How many times have we seen papers and science blown because someone made a
mistake in the 50 steps they did to get their results?

CSV > Excel

~~~
schrodinger
Not understanding how you can rank CSV vs Excel. Excel is a platform that
let's you easily build up complex calculations with different statistics,
graphs, formatting, and a lot more. CSV is an interop file format for plain
text tabular data.

Yes, I'd rather a raw dump of data in CSV than XLS, but it seems like you're
making a more general statement than that.

------
hughes
Please, please don't try the example on the front page. Putting your stripe
api key in a script on an insecure host is totally crazy.

~~~
spolu
No key on the front page visible

~~~
yebyen
No, of course not, but the example suggests you could put your key in and pull
down your invoices from stripe to do data mining on them.

------
aercolino
I don't get why should I need an app like this.. Isn't it enough to use
something like the Chrome console with jQuery.map?

------
conradfr
If you're a coder that had to generate CSV files to be opened in Excel, you
don't necessarily associate those two things as a good match :)

------
97-109-107
Seems like exactly the tool we needed just two days ago for pruning down a
49mb json file. We ended up parsing it in nodejs as it could simply spit out
the output to a file. I didn't want to risk crashing my browser again - is
there any chance that a client-side web-app parser (like yours) would be able
to handle files that big?

~~~
spolu
Yep. We are trying to push our bizdev to use it as well. It's still slightly
complicated... but they're starting to get it! :)

~~~
97-109-107
Am I missing something, but wouldn't that require pasting the 49mb file into
your app through my clipboard? Just getting a file like that into the
clipboard, let alone pasting into the browser, seems like a task in itself.

~~~
spolu
Yes you're right. 49mb is slightly large for REPL. but I've been working
successfully with 200k lines CSV of over 15mb without issue

~~~
maninalift
Your bandwidth has nothing to do with it, it runs in the browser.

All it does is JSON.parse, execute your series of functions then
JSON.stringify.

Unless I'm missing something there is no advantage over ad-hoc javascript. If
you want to load a file from disk, deserialize and do some processing in
javascript then node is absolutely the right tool (and this isn't).

------
maninalift
I don't get this at all.

I can build a pipeline of functions and view the output just as conveniently
in a plain node or browser environment and I would have much more flexibility.

Has anyone got a use case?

Anyone?

------
blueskin_
...undocumented and bloated?

------
acron0
I just don't get this.

~~~
rip747
thank god i'm not the only one.

I don't know what it is, some of the products/projects being shown on HN
lately have the problem of coherently explaining and demoing what the they do.

------
mparr4
My favorite feature is the ability to expand and collapse at the object level.
Anybody have a favorite tool for this?

------
nly
The last thing I want to use Excel for is CSV. It seems to me what JSON needs
is an equivalent to XSLT

------
duncans
Could probably do with turning those screenshots into an animated GIF as it
took me a while to work out the flow, and that presumably each stage is
persistent (I'm guessing, from the Run 0>1>2 chevrons).

------
adnans
I think this is exactly what I needed yesterday when someone asked me is it
possible to get a report from Asana into excel (Asana doesn't have this
ability, just the json API).

~~~
karamazov
Take a look at this:
[https://voyager.datanitro.com/](https://voyager.datanitro.com/)

------
cjfont
Wow, I was expecting this to get some criticism as I clicked the comments, but
this is a bit more negativity than I would have expected from HN.

~~~
threepipeproblm
More meta-negativity than anyone was expecting.

------
keenerd
[http://kmkeen.com/jshon/](http://kmkeen.com/jshon/)

------
lotsofcows
"Excel is to CSV" You mean a huge bloated mess that takes forever to load and
encourages people to turn my beautiful data into some proprietary bollocks
because they're to lazy to learn awk? Sorry, that was quite a long sentence,
let me see if I can turn it into a useless but pretty chart...

~~~
xmonkee
Pretty wrong. It's a huge bloated mess that takes forever to lead and can be
used to store data and code seamlessly in cells to make a single document
holding both presentation and logic. Excel suffers from being a microsoft
product, not from a being a bad idea. Spreadsheets are a fucking great idea.
Visual programming, code as data, etc etc.

~~~
baldfat
I disagree. It isn't reproducible AND people make mistakes and then present
papers and other outcomes that later is shown to be false.

Spreadsheets are treated as Swiss Army Knifes. People believe all they need to
do anything is Word and Excel.

~~~
schrodinger
What could the same people who are using excel have used instead that would
have prevented them from making an error in their steps of calculation?

------
freefrancisco
It would be cool if you could use coffeescript instead of js.

