To highlight the first column of a table is to utilize the table method highlightFirstColumn to set an indicator to highlight the first column of the table when it is being created.
Steps to Complete:
1. Initialize SpreadJS and add a table from data source
2. Set highlightFirstColumn to True
Step 1: Initialize SpreadJS and a table from data source
For this example, add a range table from the data source using SpreadJS’s addFromDataSource method and store it in the variable called table.
Use the following parameters to create the table:
Table Name: table
data source: dataArray
The final script tag should appear as so:
After this step, the table should appear like this:
Step 2: Set highlightFirstColumn to True
Underneath where we have added a table from the data source, set the highlightFirstColumn method to True to indicate to highlight the first column.
After this step, the table will now have the first column highlighted like so: