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

Prefilled username route #117

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

BlueBeret
Copy link

@BlueBeret BlueBeret commented May 7, 2022

Add dynamic route to prefilled the username and then fetch it.
#55

@vercel
Copy link

vercel bot commented May 7, 2022

Someone is attempting to deploy a commit to a Personal Account owned by @sallar on Vercel.

@sallar first needs to authorize it.

Copy link
Owner

@sallar sallar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

package-lock.json is not needed, this project uses yarn

setError(null);
setData(null);

fetchData(cleanUsername(props.username))
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This part is a duplicate of existing functionality. Is it possible for you to use the same code for both? (like extracting the fetch into its own function)


useEffect(() => {
if (route.split("/")[1] !== '[username]') {
console.log(route.split("/")[1])

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary log

Co-authored-by: Tanvir Islam Streame <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants