mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-22 12:01:23 +01:00
Optimized Reused Values for Loops
This commit is contained in:
parent
8ec42ca2e5
commit
234fcb09c2
19 changed files with 91 additions and 54 deletions
|
|
@ -1111,7 +1111,8 @@ function addFonts(url) {
|
|||
// Update font list for Label and Burg Editors
|
||||
function updateFontOptions() {
|
||||
styleSelectFont.innerHTML = "";
|
||||
for (let i=0; i < fonts.length; i++) {
|
||||
let numberOfFonts = fonts.length;
|
||||
for (let i=0; i < numberOfFonts; i++) {
|
||||
const opt = document.createElement('option');
|
||||
opt.value = i;
|
||||
const font = fonts[i].split(':')[0].replace(/\+/g, " ");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue