Debian Codegraph @

packages/babel-plugin-transform-classes/test/fixtures/get-set/change-computed-key/exec.js

raw
1 let x = 1;
2
3 class A {
4 get [x]() {}
5 [(x = 3, 2)]() {}
6 set [x](_) {}
7 }
8
9 expect(Object.getOwnPropertyDescriptors(A.prototype)).toMatchObject({
10 1: {
11 get: expect.any(Function),
12 set: undefined,
13 },
14 2: {
15 value: expect.any(Function),
16 },
17 3: {
18 get: undefined,
19 set: expect.any(Function),
20 }
21 });