HTML table with a variable amount of rows

I have an array with a variable amount of rows that I’m trying to create a table of. The table will be inside a popup window (SweetAlert), and the rows come from an AJAX call that is grabbing a PHP database query. The query is sent over and is viewable with console.log, but I don’t know how to format the and to loop as many times as needed, preferably with just the html and js.

How do make an axios call inside sweet alert popup on delete and show the data in dropdown inside popup?

I get a popup showing are you sure you want to delete this data? But what I want is I want to make an Axios call and fetch data inside that popup, asking where do you want to shift the data related to that data inside ? I want to Show the dropdown in that delete pop up of sweetalert showing message , where do you want to shift the content related to beacon? and show the dropdown containing the beacons that i am getting from that axios call