user3293156 user3293156 - 6 months ago 19
Python Question

Is there a javascript equivalent for the python pass statement that does nothing?

I am looking for a javascript equivalent for the python

pass
statement that does nothing. Is there such a thing in javascript?

Answer

Python's pass mainly exists because in Python whitespace matters within a block. In Javascript, the equivalent would be putting nothing within the block, i.e. {}.

Comments