JSFiddle - React, Tailwind, and code Playground

by Narcotic

HTML

When you click in the input, I would like to select all the numbers.<br />
But if you click between 2 numbers, the selected is canceled by the typing cursor.<br /> Anyway to avoid that?
<br />
<input type="text" class="class-focusin" value="4578" />
<br /><br />
Regular input<br />
<input type="text" class="class-not-focusin" value="457887" /

JavaScript

$('.class-focusin').click(function(e) {
	
	$(this).select();
    
 });