-
Notifications
You must be signed in to change notification settings - Fork 146
Automation to improve code quality and consistency #771
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
Comments
@ksen0 @davepagurek I would like to work on this issue ..? |
Hi @shivasankaran18 could you clarify please which specific problems this will help to address? 2-3 examples would be really helpful to understand what your idea here is! |
I also just saw the other issue you opened #738:
And as a result, I am renaming this issue to more reflect the general proposal of improving code quality/consistency through automation. Anyone reading is welcome to weight in! What are 2-3 concrete, currently-existing problems that would be addressed by the proposed automation(s)? and from there: which automation is most helpful? |
Yeah @ksen0.. We can have a ts-ignore check script to ensure that modification in the codebase does not include ts-ignore comments .. Adding Husky(Pre Commit Hook) to the repo checks and lints the code for every commit the developer makes .. I propose this , on every commit , we can have linting and ts-ignore check using the pre commit hook . We can also add any other code quality automations if you could suggest |
Hi @shivasankaran18 , thanks for following up! I'm more asking for why, or the motivation; I understand what you're proposing. What are 2-3 concrete, currently-existing problems that would be addressed by the proposed automation(s)? For example, are there any recent commits where these would have been helpful, and how? EDIT: Sorry I didn't mean to close it just now, clicked the wrong button. |
yeah @ksen0
|
What I'm asking about is not the theoretical problems that might happen, but whether this is an actual problem in the repository. For example, there are a few linter warnings; and use of ts-ignore as a workaround for Each of those suggested changes in automation would need, as prerequisites, to first have 2 respective PRs: one that fixes all existing linter problems; and another that removes need for ts-ignorewithout changing functionality. You are welcome to work on fixing linter problems first. Once that is finished, you could try to remove the existing use of ts-ignore. Let me know if you're interested in working on that! |
yeah got it @ksen0 .. I don't see any recent commits that have major code quality codebase . I am proposing this for future avoidance . I am happy to work on this issue .. could you assign me ? |
Hi @lirenjie95 do you have any thoughts about whether or not to add Husky / other automations for improving code quality and consistency? Pros/cons? Tagging you because of your recent PR comment. Thank you! |
Pros: 1. Third-party tools can improve code quality because they have pre-configured patterns. 2. They also save reviewers' time by preventing them from having to point out code styling issues. #820 is a good PR if it only addresses the lint warnings. I agree with @ksen0 that we currently don't have many linter warnings or errors that make this repo hard to maintain. |
Increasing Access
Adding Husky to the p5.js repository would help enforce pre-commit Git hooks for formatting, linting, or running tests, ensuring that contributions from all users—especially beginners—follow a consistent and accepted code style.
Most appropriate sub-area of p5.js?
Home
Feature request details
By automating linting or formatting on commits, contributors don’t need to worry about setting up and remembering project-specific tooling—Husky does it for them.
The text was updated successfully, but these errors were encountered: