您的位置:首页 > 其它

Masonry常见错误

2016-02-19 17:24 411 查看
1.出现NSInternalInconsistencyException错误

xcode提示:

Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Attributes should be chained before defining the constraint relation'

看看是不是吧
with
写成了
width
,比如
make.top.mas_equalTo(self.mas_top).with.offset(50);
写成了
make.top.mas_equalTo(self.mas_top).width.offset(50);


2.couldn't find a common superview for

看看是不是少了
addSubView
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: