From b745f45e1f507b6918011dad59247fb5f15c3c8f Mon Sep 17 00:00:00 2001 From: Michael Giuffrida Date: Sat, 26 Sep 2015 15:20:28 -0700 Subject: [PATCH] Allow newlines in computed binding argument list This allows breaking in the middle of computed bindings, e.g.: ```
``` Note that `[\s\S]*` [doesn't seem to have worse performance]( http://jsperf.com/javascript-multiline-regexp-workarounds/5) than `.*`. --- src/standard/effectBuilder.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/standard/effectBuilder.html b/src/standard/effectBuilder.html index 4048a0ca57..8540071329 100644 --- a/src/standard/effectBuilder.html +++ b/src/standard/effectBuilder.html @@ -169,7 +169,7 @@ // method expressions are of the form: `name([arg1, arg2, .... argn])` _parseMethod: function(expression) { // tries to match valid javascript property names - var m = expression.match(/([^\s]+)\((.*)\)/); + var m = expression.match(/([^\s]+)\(([\s\S]*)\)/); if (m) { var sig = { method: m[1], static: true }; if (m[2].trim()) {