babel / babel-eslint

:tokyo_tower: A wrapper for Babel's parser used for ESLint (renamed to @babel/eslint-parser)
https://github.com/babel/babel/tree/main/eslint/babel-eslint-parser
MIT License
2.96k stars 208 forks source link

space-before-function-paren is not working pretty good with async es6 function #751

Closed muuvmuuv closed 4 years ago

muuvmuuv commented 5 years ago

It looks like eslint has problems with async function that uses arrow functions. It throws a error where IMO it should not or am I missing an eslint option?

Error: Unexpected space before function parentheses.eslint(space-before-function-paren) Config: https://hastebin.com/oliyavicec.json Code:

test('return a translated text string for prop TEST into german (de-DE)', async () => {
  __.language = 'de-DE';                                                  ^^^^^
  const translatedString = await __.text('TEST');

  expect(translatedString).toBe('Tests');
});
kaicataldo commented 4 years ago

Thank you for the issue. Now that @babel/eslint-parser has been released, we are making this repository read-only. If this is a change you would still like to advocate for, please reopen this in the babel/babel monorepo.