change variable scope to block
This commit is contained in:
parent
2aa403d3c9
commit
d43ffbaefb
|
@ -39,7 +39,7 @@ div>label {
|
|||
|
||||
function create_element_link(element, href) {
|
||||
element.addEventListener("click", () => {
|
||||
var lnk = document.createElement('a');
|
||||
let lnk = document.createElement('a');
|
||||
|
||||
if (typeof href === "function") {
|
||||
lnk.href = href();
|
||||
|
@ -127,9 +127,9 @@ div>label {
|
|||
}
|
||||
|
||||
function update_table(bases, extensions) {
|
||||
var tdata = [];
|
||||
var base_header = {};
|
||||
var ext_header = {};
|
||||
let tdata = [];
|
||||
let base_header = {};
|
||||
let ext_header = {};
|
||||
|
||||
// first, fill base_header
|
||||
bases.forEach((base) => {
|
||||
|
@ -208,7 +208,7 @@ div>label {
|
|||
|
||||
// require in tabular-tables
|
||||
// eslint-disable-next-line no-undef
|
||||
var table = new Tabulator("#data-table", {
|
||||
let table = new Tabulator("#data-table", {
|
||||
layout: "fitDataTable",
|
||||
initialSort: [
|
||||
{column: "frequency", dir: "asc"},
|
||||
|
@ -257,7 +257,7 @@ div>label {
|
|||
});
|
||||
|
||||
table.on("tableBuilt", () => {
|
||||
var div_togglebuttons = document.getElementById("togglebuttons");
|
||||
let div_togglebuttons = document.getElementById("togglebuttons");
|
||||
div_togglebuttons.innerHTML = "<span>Toggle column:</span>";
|
||||
table.getColumns().forEach((col) => {
|
||||
let col_name = col.getField();
|
||||
|
|
Loading…
Reference in a new issue