Re:SpahQL - A query language for Javascript objects
by DonnyV on Monday May 21, 2012 @08:55AM
(#4002594)
linq.js has been doing this for years now. Its a mature library, flexible and light.
I use it for every web project, wouldn't know what to do with out it.
http://linqjs.codeplex.com/
Examples: http://neue.cc/reference.htm
[ Parent
| on HN ]
Re:SpahQL - A query language for Javascript objects
by angryamoeba on Monday May 21, 2012 @09:43AM
(#4002763)
Good utility, but I had a few specific itches to scratch with SpahQL:
* Declarative syntax for selections, such that selection queries may be handed between implementations in other languages
* Imperative syntax for updates, such that updates may be idiomatic to the language in which the spahql library has been ported (linq meets this criteria)
In essence all SpahQL is, is a shorthand syntax for generating traversal and descent functions, which output a proxy object for reading to and writing from the selected nodes.