coding-styles icon indicating copy to clipboard operation
coding-styles copied to clipboard

Immediate invocation of ES6 shorthand generator?

Open niftylettuce opened this issue 10 years ago • 0 comments

Doesn't work (throws unexpected token):

app.use(*g() {
  this.body = 'hello world';
});

Works:

app.use(function *() {
  this.body = 'hello world';
});

Any insight as to why?

niftylettuce avatar Jan 02 '16 09:01 niftylettuce