-
-
Notifications
You must be signed in to change notification settings - Fork 0
feat: updates styleguide markdown #78
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
base: develop
Are you sure you want to change the base?
Conversation
Updates the STYLE_GUIDE.md to include industry standards and best practices for TypeScript naming conventions, commenting, and imports.
| import { UserService } from '@services/UserService'; | ||
| ``` | ||
|
|
||
| ## Pull Request Instructions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add more details on what a PR should include? Basically reiterating the PR template that's shown whenever we make a PR, and what additional things or examples we can write in it.
| - **Use hot reloading** for fast feedback | ||
| - **Implement CI/CD** for automated testing | ||
|
|
||
| ``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here are some other parts that would be great if you can add:
- standard patterns of writing tests (basically I want all of our way of writing tests to be consistent)
- standard patterns of writing certain code (such as filtering/sorting - right now, we are all writing them in our own way and it would be difficult to use them if they are all each uniquely structured) for now, mainly writing rules for this is the goal - in the future, we would need to add more when it comes to creating components and such but it's not necessary at the moment.
like for filtering, i think this way looks good: #69
and so on Postman, we would call like this:
And so it would be ideal to have filter AND sorting to be structured something like this:
query {
volunteers(
filter: {
statuses: ["PROFESSIONAL", "STUDENT"],
roles: ["Developer"],
chapters: ["Cal high"]
}
sort: {
firstName: ascending
}
) {
volunteer_id
first_name
}
}
something like that so variables "sort" and "filter" are the same and not renamed to something like "sortingOrder", etc.
|
|
||
| ## Writing Code | ||
|
|
||
| - Use function declarations - not arrow functions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you add a file naming convention as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and specify for which types of files we would name in what certain way
| - **Implement CI/CD** for automated testing | ||
|
|
||
| ``` | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you also add a section of code organization? so in a file, in what order would we put our code? for example, imports are up first obviously, then we would add what? if we had variables, etc. would we put them at the very top first before the rest of our code, etc.
this is to ensure that whenever we access files, we can quickly scan for places we want to know if our code organization is consistent, which would save us time
|
Can you also mention in the style guide to add TODO comments if there is a part that's still needs to be done? |
Closes #76
Overview
Updates the STYLE_GUIDE.md to include industry standards and best practices regarding TypeScript naming conventions, commenting, and importing.
Testing
None
Screenshots / Screencasts
None
Checklist
Tip: You can make the issue and then check them after the fact or replace
[ ]with[x]to check it!Notes
Adopted styles from the following resources: