function handleClick(){
    d3.event.preventDefault() // prevent the form from refreshing the page
    
    let date = d3.select("#datetime").property("value");
    let filterData = tableData;

    // Check to see if a date was entered and filter the data using that date
    if (date){
        // Apply filter to the table data to only keep the 
        // rows where the datetime value matches the filter value
        filterData = filterData.filter((row) => row.datetime === date);

    }

    buildTable(filterData);
}
// Event that calls a function  name it handleClick
Event that calls a function  name it handleClick
Event that calls a function name it handleClick
function handleClick(){
    d3.event.preventDefault() 
    let date = d3.select("#datetime").property("value");
    let filterData = tableData;
    if (date){
        filterData = filterData.filter((row) => row.datetime === date);
    }
    buildTable(filterData);
}
function handleClick ( ) { d3 . event . preventDefault ( ) let date = d3 . select ( "#datetime" ) . property ( "value" ) ; let filterData = tableData ; if ( date ) { filterData = filterData . filter ( ( row ) => row . datetime === date ) ; } buildTable ( filterData ) ; }
Event that calls a function  name it handleClick
Event that calls a function name it handleClick
// prevent the form from refreshing the page // Check to see if a date was entered and filter the data using that date // Apply filter to the table data to only keep the  // rows where the datetime value matches the filter value