JSFiddle - React, Tailwind, and code Playground
HTML
<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/themes/ui-lightness/jquery-ui.css">
<div id="ageInput">
<div></div>
</div>
CSS
#ageInput {
margin: 60px 20px 0 20px
}
#ageInput > div {
margin-top:-25px;
position: relative;
}
JavaScript
var ageInput = $("#ageInput");
var ageDisplay = $("#ageInput > div");
var initialValue = 32;
var handle = null;
var updateSliderValue = function (event, ui) {
handle = handle || $(".ui-slider-handle", ageInput);
ageDisplay.text(ui.value || initialValue)
.css(handle.position());
};
ageInput.slider({
min: 12, max: 122,
slide: updateSliderValue,
create: updateSliderValue,
value: initialValue
});