Я получаю следующие ошибки при запуске приложения. Какая у меня проблема со зрением?
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
2019-06-15 17:45:15.916490+0300 ...[3888:779219] [LayoutConstraints] Unable to simultaneously satisfy constraints.
Probably at least one of the constraints in the following list is one you don't want.
Try this:
(1) look at each constraint and try to figure out which you don't expect;
(2) find the code that added the unwanted constraint or constraints and fix it.
(
"<SnapKit.LayoutConstraint:[email protected]#3209 ....DeviceTableViewCell:0x10c82cc00.width == 375.0>",
"<NSLayoutConstraint:0x280be41e0 'UIView-Encapsulated-Layout-Width' ....DeviceTableViewCell:0x10c82cc00'cellId'.width == 0 (active)>"
)
Will attempt to recover by breaking constraint
<SnapKit.LayoutConstraint:[email protected]#3209 ...DeviceTableViewCell:0x10c82cc00.width == 375.0>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
cell.snp.makeConstraints { (make) in
make.top.equalTo(100)
make.height.equalTo(205)
make.width.equalTo(view.frame.width)
}





Я думаю, что у вас есть 2 ограничения ширины для конкретного cell, так что проверьте это.
Или попробуйте изменить приоритет ограничения ширины.
make.width.equalTo(view.frame.width).priority(999)
Я не использую раскадровку, я сделал это с помощью визуального кода. Добавил код в тему.
Как я могу это сделать?
make.width.equalTo(view.frame.width).priority(999)@BerkooBek Рад, что смог помочь. Если мой вопрос правильный, отметьте его и проголосуйте :)
Как сделать так, чтобы он работал на всех устройствах? Я должен изменить ширину на что. Также спасибо за ответ