Cartography
Cartography copied to clipboard
Support array in `distribute`
You can't splat an array into var-args in Swift, which harms the utility of methods like constraint(views: [UIView], block: [Proxy] -> ()
There should be support for an array of views to distribute as well.
Something like
public func distribute(by amount: CGFloat, horizontally array: [LayoutProxy]) -> [NSLayoutConstraint] {
return reduce(array.first!, rest: Array(array.dropFirst())) { $0.trailing == $1.leading - amount }
}
?
Yes
Ups i missed this issue and i created a new one exactly with the same 😞 Don't know if you guys have a branch with this already, but i open a pull request with a suggestion to this