cassowary.js icon indicating copy to clipboard operation
cassowary.js copied to clipboard

Create new API shim

Open slightlyoff opened this issue 13 years ago • 2 comments

Once we have a general direction for the new API, build a shim layer to use while we transition off the old one. Once the shim is in place, the API is agreed, and all of our demo/test code uses it, remove the old API.

slightlyoff avatar Jun 21 '12 14:06 slightlyoff

I'm happy to add in more features to the new api. I'm curious what you think hierarchies and editing would look like.

asolove avatar May 13 '13 20:05 asolove

I'm porting over an existing Cassowary application and have a need to be able to add constraints of different strengths, so I've added the following:

c("a+b+c==total"); // defaults to required, like currently
c("a==10", "weak"); // specify string weight for stays 

I couldn't think of a good way to integrate the strength into the expression string syntax, but am open to suggestions. Is this something you're interested in adding to the api?

asolove avatar May 16 '13 20:05 asolove