JSFiddle - React, Tailwind, and code Playground

HTML

<input onclick="test()" text='test' type='button' />

JavaScript

$( document ).ready(function() {
    var pList = new Object();
    pList["test"] = "test";
    pList["test1"] = "test1";
    pList["test2"] = "test2";
    pList["test3"] = "test3";
    pList["test4"] = "test4";
    
    displayData(pList);
    
    console.log(pList);
});

function displayData(badData){
    delete badData.test;
    
    console.log(badData);
}