Skip to content

Private Properties phase 1#7666

Merged
jridgewell merged 3 commits intobabel:masterfrom
jridgewell:private3
Apr 5, 2018
Merged

Private Properties phase 1#7666
jridgewell merged 3 commits intobabel:masterfrom
jridgewell:private3

Conversation

@jridgewell
Copy link
Copy Markdown
Member

@jridgewell jridgewell commented Apr 4, 2018

Co-authored-by: @CodingItWrong

We keep getting stalled on Class Private Properties. This is an attempt to take all the small parts into a separate PR, so we can make some progress.

Part of #7555.

@jridgewell jridgewell added PR: New Feature 🚀 A type of pull request used for our changelog categories Spec: Class Fields labels Apr 4, 2018
Co-authored-by: CodingItWrong
@babel-bot
Copy link
Copy Markdown
Collaborator

babel-bot commented Apr 4, 2018

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/7452/

this.semicolon();
}

export function ClassPrivateProperty(node: Object) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should also print the decorators. Also, do Flow and Ts support type annotations?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll leave that for later PRs. Small bits, so we don't get stalled again.

validate: assertNodeType("PrivateName"),
},
value: {
validate: assertNodeType("Expression"),
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

optional: true?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

Copy link
Copy Markdown
Member

@existentialism existentialism left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I think babel-types docs need to be regen'd after setting it setting ClassPrivateProperty to optional

@jridgewell jridgewell merged commit 43040a4 into babel:master Apr 5, 2018
@jridgewell jridgewell deleted the private3 branch April 5, 2018 10:17
@jridgewell jridgewell restored the private3 branch April 9, 2018 17:23
@lock lock bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Oct 5, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: New Feature 🚀 A type of pull request used for our changelog categories Spec: Class Fields

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants