Skip to content
This repository has been archived by the owner on Aug 18, 2021. It is now read-only.

support classPrivateMethods #729

Closed
wants to merge 1 commit into from
Closed

support classPrivateMethods #729

wants to merge 1 commit into from

Conversation

neyasov
Copy link

@neyasov neyasov commented Dec 5, 2018

No description provided.

@SeinopSys
Copy link

I'm running into babel/eslint-plugin-babel#166 and now I'm wondering if this would fix it.

@hzoo
Copy link
Member

hzoo commented Dec 11, 2018

Can you include a test case as well to make sure it's fixed? This is correct from a plugin point of view but curious if that's all that's needed.
Something like this

it("SpreadOperator", () => {
parseAndAssertSame("var a = { b, ...c }");
parseAndAssertSame("var a = [ a, ...b ]");
parseAndAssertSame("var a = sum(...b)");
});

and maybe a non-regression test like checking some rules are working

@nrei0
Copy link

nrei0 commented Dec 16, 2018

Hey, not works for me, it produces a lot of weird eslint errors.
But babel compiles private methods without any problems.

@cKiril
Copy link

cKiril commented Jan 8, 2019

Can anyone comment on the status of this? I'm running into this error message with ESLint 5.12

ESLint: Parsing error: This experimental syntax requires enabling the parser plugin: 'classPrivateMethods'

  189 |    *                     false otherwise.
  190 |    */
> 191 |   #set(key, value = null) {
      |   ^
  192 |     if (typeof key !== 'string') {
  193 |       return false;
  194 |     }

@SeinopSys
Copy link

@cKiril I tried asking about the same issue on Stack Overflow but nobody responded.

@kaicataldo
Copy link
Member

This should be fixed by #711

@hzoo
Copy link
Member

hzoo commented Jan 10, 2019

From #711, we shouldn't need to update this type of change anymore (babel-eslint should read from your babel config which will turn on or off for babel-eslint which is a better long term solution

@hzoo hzoo closed this Jan 10, 2019
@WangJiangJiaoZi
Copy link

Eslint doesn't work well with Babel and often throws exceptions in vs code.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants