Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on May 17, 2021. It is now read-only.

Commit 0dfa53d

Browse files
rueckstiessscottsidwell
andauthored
dont use ES6 syntax in grammar (#21)
* dont use ES6 syntax in grammar In c8b9e2 we removed transpilation to ES5, which broke Charts e2e tests. * Update grammar.pegjs Co-Authored-By: Scott Sidwell <38820281+scottsidwell@users.noreply.github.com> Co-authored-by: Scott Sidwell <38820281+scottsidwell@users.noreply.github.com>
1 parent c8df9b3 commit 0dfa53d

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

‎grammar.pegjs‎

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -183,14 +183,17 @@ geometry_point
183183
distance:(
184184
value_separator quotation_mark operator:distance_operator quotation_mark
185185
name_separator value:number_positive
186-
{ return { [operator]: value }; }
186+
{
187+
var result = {};
188+
result[operator] = value;
189+
return result;
190+
}
187191
)*
188192
end_object
189193
{
190-
return {
191-
"$geometry": geometry,
192-
...(distance ? distance : {})
193-
};
194+
var result = distance || {};
195+
distance.$geometry = geometry;
196+
return result;
194197
}
195198

196199
geometry_type

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /