Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

$star$opt$star in optional arguments in React components #4129

Closed
jfrolich opened this issue Jan 31, 2020 · 0 comments
Closed

$star$opt$star in optional arguments in React components #4129

jfrolich opened this issue Jan 31, 2020 · 0 comments

Comments

@jfrolich
Copy link

In upgrading to 7.0.2-dev.2 from 7.0.1

- var match = Props.neutral;
- var neutral = match !== undefined ? match : false;
+ var $staropt$star = Props.neutral;
+ var neutral = $staropt$star !== undefined ? $staropt$star : false;

for a component like this:

[@react.component]
let make = (~neutral=false) => {
  ...
}

It would be great if this variable would contain the name of the prop (or be more descriptive as $staropt$star.

@jfrolich jfrolich changed the title $star$opt$star in optional arguments in react-components $star$opt$star in optional arguments in React components Jan 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant