Originally went to school for painting and printmaking, played in bands, and have now been designing and developing since 2010. I write the curriculum and teach at Perpetual Education.
In JS you can do that when there's only 1 parameter in some cases. However, I much prefer the consistency to just always use the same convention. If it's always parentheses then it's easier for a larger team to read.
todayilearned In Ruby, you can forego the parenthesis in methods if you don't have any parameters. That's clutch.
In JS you can do that when there's only 1 parameter in some cases. However, I much prefer the consistency to just always use the same convention. If it's always parentheses then it's easier for a larger team to read.
I didn't know that re: JavaScript! But I agree, especially with JS where its very bracket/parenthesis/semi-colon reliant.