onkey will contain the value when the toggle switch is on, and the
offwill contain the value that is set when the switch is off. If
checkedis set to true the checkbox will be toggle on; otherwise by default it will be off.
defaultif one has not been set and in the
optionsobject you will specify the value of the option on the left and the text to be displayed on the right.