JSFiddle - React, Tailwind, and code Playground

by dauruk0512

HTML

test 1:<input type="text" id="keyboard">

test 2: <input type="text" id="total" value="5">

JavaScript

$("#keyboard").keyup(function(){
	var keyboard = $(this).val();
	
	var total = $("#total").val();
	
	 
	  if ( parseInt(keyboard) > parseInt(total))
		 
		 {
			 alert ('stock not enough');
		 }
	//alert (keyboard);
  });