-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
docs: add linters description #3945
Conversation
Hey, thank you for opening your first Pull Request ! |
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.
Hey @ldez! Thank you. I do have frontend knowledge but I actually never worked with Gatsby before. But let me take a look at the issues and I'll see what I can do about them :) |
@AlduLonghi have you taken a look? Can you help us? If you cannot it's not a problem, I'm just trying to use the opportunity 😺. |
Hi @ldez! I've been exploring it the past week and it has to do with Gatsby Migration from v4 to v5. There are some plugins that are not migrated to their latest versions (some needed to be migrated during gatsby migration v3 - v4) and they need code refactoring to function correctly. Is this just this rabbit hole of migrating everything and checking everything works correctly. I might be able to take this next week if that's ok :) |
What?
resolves #3927
The idea was to add the description for each linter before the snippet in the /linters section.
Additional
I added a formatting function that normalizes all linters' descriptions. This function uppercases the first letter and adds a final dot if missing.
Why?
This is for better understanding so the user doesn't have to scroll all the way up to read the linter's description.
How?
I call the function GetAllSupportedLinterConfigs() and create a map with each linter's name and description. This way I decrease the complexity since I use just one loop to make it and the later search is O(1).
Testing?
Everything is working fine.
Screenshots
From this:
To this:
Additional
From this:
To this:
Looking forward to your comments :)