by adwf · 12y ago · 0 comments
I can imagine some complicated websites getting out of hand quite quickly.
The GSS website is a good example, with about 400 atomic constraints on the homepage. Major bottleneck is reading / writing DOM, resolving element queries; not Cassowary's constraint resolution.
GSS uses the canonical JS port of Cassowary maintained by Alex Russell:
https://github.com/slightlyoff/cassowary.js
Adam Solove had a good JSConf talk on Constraint Programming in the Browser that touches on Cassowary.js & perf benefits:
The point is that you don't have to re code an entire set of equations for a new layout. That's big for designers to not have to involve coders (in theory).