Add custom error messages for console
We should add custom error messages to the console for components that depend on third party data like Twitter, Github projects and podcasts. This would clear confusion for users and visitors both on why some components are missing.
Related to #165
Hi. I would like to work on this issue.
Alright, assigning this to you @SamratDe !
@kartikcho I am fixing the warning messages in console first, because I think if there are too many messages in the console, users will have difficult time in finding the error message for components not loading. Is it ok to do so? Most of the warning of messages are not missing key prop or misspelling prop name or classNames etc.
@SamratDe they don't show up in the production deployment so custom messages would still be on top. #138 has fixed these errors but we haven't merged it in yet because of the dark mode PR. Maybe you can follow up in another PR if there are still any messages left after that PR gets in, I appreciate the help!
Ok. Then I will only concentrate on adding error messages in the components.
@kartikcho I have created a PR.
@kartikcho I have made a PR that will close this issue, feel free to look into it and let me know if that is fine. Thanks.
@kartikcho if this issue is open then I would like to take it
Sure @Rispectech! You can read the discussion above before opening a PR and ask if you have any questions.
I would suggest you to do one issue before taking more at once to keep other tasks available for other peeps too. (also easier to work this way)
Thanks a lot @kartikcho . yeah u are right sorry got a bit ahead of myself
What I got from the above discussion, u need an error message on the console given the information from the external APIs is null. so sure it looks good my suggestion is we can set some default values if we don't get the information along with the error messages on the console. please tell me whether it is good enough. also, can I get your discord id or something? I would be extremely delighted if we can talk and can clear any confusion in case
Yes error messages on the console would be best. Also, I think default values would defeat the purpose of adding errors since we want them to blow up in the user's face to tell them that stuff isn't working. Just make sure to throw informative errors that would help users find out what's wrong.
Also, we can keep the discussion here as a sort of documentation to refer back to or in case someone needs to pick up on this issue in the future!
okay done will start working asap and what u think about displaying the error like "this missing" on the UI along with the console message
I have another doubt like in portfolio.js most of the values are hardcoded from the demo one so where are u receiving information from APIs?
hey since you didn't reply today, so I complete the error message handling according to my understanding. So can I submit my PR request?
Hey @Rispectech!
what u think about displaying the error like "this missing" on the UI along with the console message
I think data dependent UI components (like twitter) have a fallback message so just add console messages in your PR.
where are u receiving information from APIs?
We run a workflow script to fetch data every week, see fetch.js for the exact implementation.
So can I submit my PR
Yeah sure!
Submitted the PR @kartikcho #430. Please check and review whether I need to do something else Thanks
Thanks for the merge @kartikcho
Would like to work on more issues after I figure my stuff around
Fixed in #430