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

Enhance/rest nextjs api routes #4975

Open
wants to merge 7 commits into
base: latest
Choose a base branch
from

Conversation

mayank1513
Copy link
Contributor

@mayank1513 mayank1513 commented Jul 21, 2023

Fixes #4974

Refractor code to match community standards

  • Remove unnecessary React.FC syntax
  • Extract Layout to _app.tsx (No need to add layout on every page)
  • Use absolute path uniformly - remove import ../.., etc.

Update UI to reflect functionality properly

  • SignUp button should be renamed to "Add Author"
  • /signup route should be renamed to /add-author
  • On create post page, email input should be changed to select (As only those emails that exists in users table can be added there)
  • Remove legacyBehaviour and update links

Refractor code to match community standards
- Removed unnecessary React.FC syntax from components folder
- update .gitignore to ingore package-lock files
Refractor code to match community standards
- Extract Layout to _app.tsx
- removed long `../..` pattern
- makes refactoring/rearranging files easy
Refractor code to match community standards
- Removed unnecessary React.FC syntax from pages
- There is no login or signup mechanism.
- Signup button adds new author
- This commit simply renames UI text to reflect that more clearly
- Change authorEmail Input field to select
- This is much better as Author email must exist in users table
- fix imports
@mayank1513 mayank1513 closed this Jul 21, 2023
@mayank1513 mayank1513 reopened this Jul 21, 2023
@mayank1513
Copy link
Contributor Author

image

@mayank1513
Copy link
Contributor Author

Hi,

anybody here?

@mayank1513
Copy link
Contributor Author

Is this repo deprecated?

@jharrell
Copy link
Member

Hi there! Apologies for not seeing this back when you opened it. I tried my hand at fixing merge conflicts and failed spectacularly. If you're still interested in this, would you mind correcting the merge conflicts? I will then give this the go ahead.

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.

Improve Next.js Rest API example
2 participants