We only need jQuery UI for this! The toggleSwitch – a jQuery toggle switch button plugin, to help us create nice toggle switch buttons easy.
A jQuery toggle switch button plugin – jQuery.UI.toggleSwitch
This toggle plugin was developed for web project, that already run with jQuery UI, so don’t need extra libraries. The toggleSwitch plugin draws upon the theme .ui-slider for the look and feel, and can be applied to select elements with two child options. We can get a nice result quickly: