LabelSwitch
LabelSwitch copied to clipboard
IB Crash
The Interface Builder crashes with the following error:
Pods/LabelSwitch/LabelSwitch/Classes/LabelSwitch.swift: 63: 28: Fatal error: Use of unimplemented initializer 'init(frame:)' for class 'LabelSwitch.LabelSwitch'
I think the only thing required is to implement init(frame:)
. It could be as simple as this:
public override init(frame: CGRect) {
self.init(center: .zero, leftConfig: .defaultLeft, rightConfig: .defaultRight)
}
Thanks for you report, I will check it
Would you please tell me more detail about how this will happen? cause I can not reappear this issue in my example project. @FreshSkyler Any information would be a lot of help.
Sure! This Stack Overflow post describes the symptoms (it's a different library, but has the same problem). The accepted answer describes how to find the crash log, and this comment explains how to fix it.
Cause I have update the lib, can you update to the newest version and check if this issue still exists.