The Code
            
// get start/end numbers from inputs
// Entry point AKA Controller function
function getValues() {
  let startValue = document.getElementById("startValue").value;
  let endValue = document.getElementById("endValue").value;

  let startNumber = parseInt(startValue);
  let endNumber = parseInt(endValue);

  let numbersArray = generateNumbers(startNumber, endNumber);
  displayNumbers(numbersArray)
};



// generate numbers to display
// business/logic function
function generateNumbers(start, end) {

  let numbersArray = [];

  for (let i = start; i <= end; i++) {
    numbersArray.push(i);
  }

  return numbersArray;
};

// places generated numbers on a page AND bolding prime numbers
// View function
function displayNumbers (numbers) {

  let results = '';

  const isPrime = (num) => {
    if (num < 2) return false;
    for (let i = 2; i <= num/2; i++) {
      if (num % i === 0) return false
    }
    return true;
  }

  for (let i = 0; i < numbers.length; i++) {
    let currNumber = numbers[i];

    if (isPrime(currNumber)) {
      results += '<tr><td class="evenBold">' + currNumber + "</td></tr>";
    } else {
      results += "<tr><td>" + currNumber + "</td></tr>";
    }


  }


  let tableBody = document.getElementById('results');
  tableBody.innerHTML = results;
};


            
          

There are three key functions that make this program run properly:

getValues

this function searches our HTML by ID for a corresponding value that the user enters

generateNumbers

this function will take our two values and create an array of every number between them. Using a for loop (1, 5) becomes [1, 2, 3, 4, 5]

displayNumbers

this function not only displays our numbers on the document, but it checks each number to see if it meets a condition, and it can alter certain numbers in any way we tell it to. This function could easily be programmed to have all multiples of three in italics, or only display numbers that contain a zero, etc.

it disseminates prime from non-prime by taking a given number and checking the remainder when it's divided by any lower number, starting with 2 (since dividing by 0 or 1 is not helpful).

An additional piece of efficiency in the code is that it stops checking remainders if you are trying to divide by a number greater than half of itself.

For example, when checking if 7 is prime, we skip 0 and 1, we try to divide by 2 but don't get a whole number. We try again with 3, and still no whole number. But is there any reason to divide by 4, 5, 6, or 7? Once you start dividing by numbers greater than half of their own value, you're guaranteed to fail to find a whole integer. So the code ceases trying, and declares 7 to be prime.