javascript – Does this class creator for a simple text game seem convoluted?

I would prefer something that would be along my lines for the simplification, area of introduction to Jquery and arrow functions, though I want to get better, and this is the best way I know how.

I want it to be also a bit more efficent.

function GeneratePersonWithList(amountOfItems) {
  var items = ()
  var shL = ()
  var m = getRandomInt(1000)
  console.log(m)
  function getRandomInt(max) {
    return Math.floor(Math.random() * max);
  }
  class People {
    constructor(money, sL) {
      this.money = m
      this.sL = sL = shL + " "
    }
    shoppingListUpdate() {

    }
  }
  class item {
    constructor(id, name, price) {
      this.id = id
      this.name = name
      this.price = price
      items.push((id, name, price))
    }
  }
  function itemCreation() {
    new item(0, "Candy Bar", 1)
    new item(1, "Gum", 0.5)
    new item(2, "Apple", 5)
    new item(3, "Banana", 6)
  }
  itemCreation()
  function shoppingList(amountOfItems) {
    for (i = 0; i < getRandomInt(amountOfItems) + 1; i++) {
      shL.push(" " + items(getRandomInt(items.length))(1))
    }
  }
  let PeopleNames = "./PeopleNames.json"
  let request = new XMLHttpRequest();
  request.open('GET', PeopleNames)
  request.responseType = 'json';
  request.send();
  request.onload = function () {
    const Names = request.response;
    function Genders(Gender) {
      if (Gender === 0)
        return Names.firstNamesF(getRandomInt(999)) + " " +
          Names.lastNames(getRandomInt(986))

      else if (Gender === 1) {
        return Names.firstNamesM(getRandomInt(999)) + " " +
          Names.lastNames(getRandomInt(986))
      }
    }
    Generator = Genders(getRandomInt(2));
    function getRandomInt(max) {
      return Math.floor(Math.random() * max);
    }
    var div = document.getElementById("name")
    div.innerHTML = Generator
  }
  shoppingList(amountOfItems)
  var Person = new People()
  var div = document.getElementById("1")
  div.innerHTML = `$${Person.money} n`
  var div = document.getElementById("2")
  div.innerHTML = `Shopping list:${Person.sL}`
  console.log(div.innerHTML)
}
var but = document.getElementById("List")
but.addEventListener('click', function () { GeneratePersonWithList(10) })