I have often seen the trick
after = +after;
to coerce the variable after to a number. Reading through the Node.JS source I fou
Yes, however note that it is only the unary + operator that does this. I.e. 10 + "10" will give you "1010".
A perhaps less error prone option is to use what asm.js does:
10 + ("10"|0)
Although on the down-side it does require the brackets. It should be the fastest option in any case (probably equal to unary +).