assets/js/search.js
Function listResults
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function listResults (searchString, data, highlightMessage) {
const items = data.items; let list = '<ul>'; let max = 5; let resultsAdded = 0; let link; let localResults = false
// Return a max of 5 results.
for (let i = 0; i < items.length && i < max; i++) {
// Set item = file name without the ".md" extension.