Dependencies
$tableSelect = $k->tableSelect('names')
->setTitle($this->t('Names'))
->appendHeaderColumn('first', $this->t('First Name'))
->appendHeaderColumn('last', $this->t('Last Name'))
->appendHeaderColumn('suffix', $this->t('Suffix'))
->appendHeaderColumn('nickname', $this->t('Nickname'))
->setOptions([
'henry' => [
'first' => 'Henry',
'last' => 'Jones',
],
'anna' => [
'first' => 'Anna',
'last' => 'Jones',
],
])
->appendOption('jr', [
'first' => 'Henry',
'last' => 'Jones',
'suffix' => 'Jr.',
'nickname' => 'Indiana',
]);