JSFiddle - React, Tailwind, and code Playground
HTML
<input type="text" id="phone"/>
JavaScript
$('#phone').keyup( function (){
if ( this.value.charAt(0) != 6 && this.value )
this.value = '6' + this.value;
});
<input type="text" id="phone"/>
$('#phone').keyup( function (){
if ( this.value.charAt(0) != 6 && this.value )
this.value = '6' + this.value;
});