
DataTables – Table plug-in for jQuery - Eyes2design
http://www.datatables.net
======
theallan
DataTables author here - I've often wondered what article or software I might
write to see if I could get onto the hacker news front page. Apparently the
trick is to wake up one morning and be very pleasantly surprised to see
existing software already there :-)

Very happy to answer any questions if anyone has any!

~~~
johnny_reilly
Hi theallen,

I've made a great deal of use of jqGrid which I've found to be an excellent
piece of software. I've always been meaning to give DataTables a try as well
but haven't yet got round to it. Assuming you're aware of jqGrid how would you
compare / contrast it with DataTables?

~~~
theallan
Absolutely aware of jqGrid, but to be honest I can't comment on how it
compares to DataTables has I've never really worked with jqGrid. Perhaps I've
taken the wrong approach, but I've tended not to look at the other table
libraries, focusing instead on making DataTables as good as I can for its
intended purpose on its own. Having said that, I'm sure there is inspiration I
can take from the other libraries, as some are very impressive.

------
debaserab2
While I have found DataTables to be useful in the past, there are (thankfully)
many other alternatives available today with a much saner API.

DataTables might have the worst API I've ever seen in a Javascript library.
Powerful, yes, but it has the most insane naming conventions I've ever seen.
To this day I do not understand why so many properties are prefixed with
random letters.

There was a time when there wasn't anything else out there that was even close
to as good, though.

~~~
shoebappa
Can you name a few of the alternatives you found? The ability to sort on more
than one column ruled out a lot of them for us.

~~~
jonaldomo
[https://github.com/Mottie/tablesorter](https://github.com/Mottie/tablesorter)
has multiple sorting using the shift key. I alternate between this and
DataTables. The hungarian notation threw me off at first too. Far from insane
though.

~~~
debaserab2
Here's an example of what you have to do in datatables to get the elements
displayed around the table itself styled (such as a search bar, pagination, or
table meta information)

[https://datatables.net/release-
datatables/examples/basic_ini...](https://datatables.net/release-
datatables/examples/basic_init/dom.html)

So, in order to adjust the styling of DOM elements around the datatable, you
need to understand a very specialized form of syntax that one particular
property that controls all DOM element layouts accepts as a string. And
there's only one example.

How is that sane?

~~~
arethuza
To control the structure of whats put in the DOM your are going to need
something that looks like a template - so it's never going to be pretty and as
soon as you choose any approach to templating it's probably going to upset a
lot of people.

I agree that the syntax is a bit on the terse side - but it's not "insane" and
at least it is there, logical and documented.

------
shrikant
1\. Keep Excel spreadsheet in a shared network location

2\. Set to autogenerate webpage on every save

3\. Clean up crufty HTML with jQuery

4\. Display using DataTables

5\. Proit!

This hacky hackerson of a hack was great way to get around having to build a
CRUD app and go through IT channels to have something deployed on the network,
and still keep things simple enough for extremely entry-level end-users.

Thanks for DataTables, Allan!

------
epoxyhockey
Make DataTables editable with this addition:
[https://code.google.com/p/jquery-datatables-
editable/](https://code.google.com/p/jquery-datatables-editable/)

It is really fantastic for that _live spreadsheet_ feel.

------
jph
Paid support is excellent. I use DataTables in some client projects, and
wanted to speed up my use of it.

I paid for support and had the author's full attention the same morning. Works
like a charm.

------
vyrotek
Well this was random. I literally started using DataTables for the first time
just today for a new project. I must admit, the Hungarian notation is a bit
distracting at first. The documentation could be better as well.

In the past I've used dgrid with the DojoToolkit. It's not for everyone, but
it was great to work with.

[http://dojofoundation.org/packages/dgrid/](http://dojofoundation.org/packages/dgrid/)

[http://demos.dojotoolkit.org/demos/themePreviewer/demo.html](http://demos.dojotoolkit.org/demos/themePreviewer/demo.html)

------
Eyes2design
Using table management with my current robust Coffee script Nodejs project.
I'm going to have Fun. Mostly I can only classified myself as a home-school
ged self-study (Op Dev) but its always fun to read and work with other's code.
do you have any idea when you will have 1.10 out in the public? is their a git
hub I can look at? ..

Food for thought Magento maybe able to run some faster admin tables with this.
though, I would think this would be a task in setting up. The Json is their
but admin panels setup is another thing in Magento.

------
d0m
I'm using it in a project presently, it's a very powerful library. The project
started simple.. but the table part quickly grow very complex and that plugin
never let me down. The best part of the documentation is the examples IMHO.

There are also very good plugins[1] to use it on the backend..

[1] [https://bitbucket.org/pigletto/django-datatables-
view](https://bitbucket.org/pigletto/django-datatables-view)

------
ndesaulniers
Hell yeah, I used DataTables in my iTunes in the browser clone. [0] But it's
not super new, not sure why it's up here. It also isn't the greatest for
responsive design. That said, it's still great, and my favorite feature is
search.

[0]
[https://github.com/nickdesaulniers/audiostream](https://github.com/nickdesaulniers/audiostream)

------
iriche
I wrote a small library in Python for DataTables when I got tired over that
there was no easy way of doing backend processing for it.

[https://github.com/starstable/PonyTable](https://github.com/starstable/PonyTable)

Warning, probably not PEP-8 and can probably be improved in a tons of places.

------
Davertron
Do you still have to set the column widths explicitly? That was one of the
main reasons I had to drop this lib, because we had dynamic data and I didn't
want to deal with adding a bunch of JavaScript on top to resize columns on the
fly when the data changed.

------
misiti3780
I use this in a ton of different projects. Besides the fact that it is an
awesome library, I love pushing all of the sorting work to the client side
(and telling anyone who complains about the speed that it's their browser's
fault :) )

------
dbieber
I used these when interning at Khan Academy this summer for an internal tool
for video creators. Really very easy to get up and running, and looks good to
boot.

------
gesman
Best thing to make sexy tables since the beginning of time

------
b3n
Does anyone know how this compares to jTable
([http://www.jtable.org/](http://www.jtable.org/))?

------
warpech
If you need editable tables, I wrote this
[http://handsontable.com/](http://handsontable.com/)

------
mithras
It's a behemoth, but a very useful one.

------
cobookman
Such a useful plug-in for CRUD WebApps.

------
anupshinde
Whats new about this? Used this in the past - not anymore - there are better
alternatives these days.

