Skip to content

Instantly share code, notes, and snippets.

@davidgilbertson
Created July 5, 2018 11:31
Show Gist options
  • Save davidgilbertson/0a724dab17d0326a958234e3eb6106a6 to your computer and use it in GitHub Desktop.
Save davidgilbertson/0a724dab17d0326a958234e3eb6106a6 to your computer and use it in GitHub Desktop.
const tableEl = document.querySelector('table');
const headerRow = tableEl.createTHead().insertRow();
headerRow.insertCell().textContent = 'Make';
headerRow.insertCell().textContent = 'Model';
headerRow.insertCell().textContent = 'Color';
const newRow = tableEl.insertRow();
newRow.insertCell().textContent = 'Yes';
newRow.insertCell().textContent = 'No';
newRow.insertCell().textContent = 'Thank you';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment