I've written 99 rows of code within my function. And when I had trying to add a new one(just by clicking Enter inside), I have seen that color of my function curly brackets changed from green to red. It seems like in-built restriction of google apps script, but I haven't found anything about it... So, what is the reason of changing color? Are there other technical restrictions exist?
Asked
Active
Viewed 257 times
1 Answers
2
It is only a limitation of the syntax highlighting within the Script Editor, your function will still execute as normal, even if it is much longer than 100 lines.
I have noticed this on many occasions and wasted some time trying to find the cause, thinking it was due to a syntax error in my code. Eventually I realized that if there was too much space between the braces the highlighting no longer worked. However I didn't know the limit was precisely 100 lines, so thank you for that information :)

Cameron Roberts
- 7,127
- 1
- 20
- 32