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

Multiline Comments Style guideline // or /** */ #6332

Closed
zelf0 opened this issue Aug 7, 2023 · 3 comments · Fixed by #6334
Closed

Multiline Comments Style guideline // or /** */ #6332

zelf0 opened this issue Aug 7, 2023 · 3 comments · Fixed by #6334

Comments

@zelf0
Copy link
Contributor

zelf0 commented Aug 7, 2023

Topic

Working on https://github.com/processing/p5.js-website/issues/1385, there is discussion about the current style guideline for multiline comments, which is to "Use /** ... */ for multiline comments."

There isn't a reason provided as to why that format is better than others, and currently the example code seems to be using // for multiline comments. Should we revise the style guide to recommend using //, since its what contributors seem to be defaulting to, and it's more common since it's the default way text editors comment out code automatically. It also might be more accessible for beginners to only have to use one commenting format for comments, whether they are single or multiline.

@nickmcintyre
Copy link
Member

@zelf0 thanks for the suggestion—all sounds good to me.

@Qianqianye
Copy link
Contributor

Thanks @zelf0 for the suggestion. @nickmcintyre, please feel free to open a PR to update the documentation_style_guide.md. Thanks!

@nickmcintyre
Copy link
Member

@zelf0 how about you handle this PR since you made the suggestion?

zelf0 added a commit to zelf0/p5.js that referenced this issue Aug 8, 2023
Change style guideline for multiline comments to use // reesolving processing#6332
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants