jhawk (John Hawkinson)

Member since
jhawk

Recent Docs Activity

View all activity
Page Date Comment

Destructuring assignment


Revert to revision of 2018-03-07 07:39:12.962223 by jhawk: "No. This is wrong for the value of b, and also removes the "brush: js" styling. There may be utility in showing non-sequential object destructuring, but it's probably best as an additional examp

Destructuring assignment


Revert to revision of 2018-02-21 06:47:26.575020 by delete12345: "Revert. Left-hand side means the LHS of the equals sign, not LHS of the bracketted expression (that is instead expressed as "trailing" rather than RHS)."

Destructuring assignment


Make clear that array destructuring of a regexp match requires a test to see if Regexp.prototype.exec() or String.prototype.match() returns null. Otherwise it's too easy to look at this page and write [, foo, bar] = /(\w+,\w+)/.exec("1,2"); that can fail