17
votes
2answers
2k views

Array Like Objects in Javascript

I'm wondering how jQuery constructs it's array like object. The key thing I'm trying to work out is how it manages to get the console to interpret it as an array and display it as such. I know it has ...
77
votes
7answers
30k views

Create an empty object in JavaScript with {} or new Object()?

There are two different ways to create an empty object in JavaScript: var objectA = {} var objectB = new Object() Is there any difference in how the script engine handles them? Is there any reason ...
7
votes
2answers
111 views

javascript methods that can not be called from jquery objects?

I was reading Learning jQuery 1.3 jonathan chaffer and karl swedberg and while sorting table , they used .get() before calling .sort(), and said we need to transform jqurey objects into array of DOM ...
3
votes
2answers
1k views

Underscore.js groupBy multiple values

Using Underscore.js, I'm trying to group a list of items multiple times, ie Group by SIZE then for each SIZE, group by CATEGORY... http://jsfiddle.net/rickysullivan/WTtXP/1/ Ideally, I'd like to ...
1
vote
2answers
71 views

Performance concerns when storing data in large arrays with Javascript

I have a browser-based visualization app where there is a graph of data points, stored as an array of objects: data = [ {x: 0.4612451, y: 1.0511} , ... etc ] This graph is being visualized ...