JSFiddle - React, Tailwind, and code Playground

HTML

<html>
<head>
<title> Aggregates </title>
</head>
<body>
<h1> Aggregates </h1>
<h3> enter numbers to add </h3>
<form id="calculatorForm">
<label>number to add to list <input type="text" name="numToAdd" value="0"></input></label><br>
<button type="button" onclick="addNumToList(form)">add number to list</button> 
<input type="button" value="Reset Form" onClick="this.form.reset()" />
</form>








<div id="dsply"></div>
<script>
numList = [];
var dsply=document.getElementById("dsply");
function addNumToList(frm){
var num = frm.numToAdd.value;
frm.numToAdd.value = "";
if(isNaN(Number(num)) || num == ""){
return;
}
numList.push(num);    
dsply.innerHTML = numList.join(" + ");
if(numList.length != 1){
dsply.innerHTML += " = " + eval(dsply.innerHTML);
}
}
    
YUI().use('node',function(){
alert('yui is ready')
})    
    
</script>
</body>

JavaScript

alert('ooch')