In standart Defold code editor in right code listing (see screen), please add red lines that describe positions of code errors. It will help visually searching errors in large scripts.
This kind of visual help has Rider editor.