Open ghost opened 3 years ago
The published gem has webpack-ed/babel-ed turfjs targetting node@8. I think the error was caused by your underlying execjs backend is an older version of node.js (assuming it's node.js). If that's the case, possibly there are 2 workarrounds:
https://github.com/layerssss/turfjs-ruby/blob/master/webpack.config.js#L22
Anyway, can't imagine you've figure it out without any docs.
@layerssss thanks for the information. I should normally be using node 14, so I don't think that's the problem. I will get back to you when I have more information.
@henri-cowboy then it might be because the execjs is using other backends instead of node.js? If you have one of the gems here https://github.com/rails/execjs
I get a SyntaxError with this code:
Output:
Any idea why this is happening here?