mirror of
https://github.com/CaiJimmy/hugo-theme-stack.git
synced 2025-04-29 20:13:31 +08:00
Use const keyword for constant arrays
This commit is contained in:
parent
36da8b3254
commit
bd473b0314
@ -76,7 +76,7 @@ class Search {
|
||||
lastIndex = 0,
|
||||
charCount = 0;
|
||||
|
||||
let resultArray: string[] = [];
|
||||
const resultArray: string[] = [];
|
||||
|
||||
while (i < matches.length) {
|
||||
const item = matches[i];
|
||||
@ -139,7 +139,7 @@ class Search {
|
||||
}).join('|'), 'gi');
|
||||
|
||||
for (const item of rawData) {
|
||||
let titleMatches: match[] = [],
|
||||
const titleMatches: match[] = [],
|
||||
contentMatches: match[] = [];
|
||||
|
||||
let result = {
|
||||
|
Loading…
Reference in New Issue
Block a user