JSFiddle - React, Tailwind, and code Playground
HTML
<input type="text" name="tooltip" id="samplebox" data-toggle="tooltip" title="Ankit">
<input type="text" name="tooltip" id="samplebox1" data-toggle="tooltip" title="Ankit">
<input type="text" name="tooltip" id="samplebox2" data-toggle="tooltip" title="Ankit">
<input type="text" name="tooltip" id="samplebox3" data-toggle="tooltip" title="Ankit">
JavaScript
$("[data-toggle=tooltip]").mouseenter(function () {
var $this = $(this);
$this.attr('title', $this.val());
});