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

Add supabase connection #8

Open
wants to merge 3 commits into
base: optimize-code
Choose a base branch
from

Conversation

thetiagogil
Copy link
Collaborator

@thetiagogil thetiagogil commented Jan 23, 2025

This PR adds supabase connection.

  • Installed supabase library and added supabase connection via supabase.ts file;
  • Added users table to supabase (with the model src/models/user.model.ts);
  • Added useUserApi.ts file to handle connections with users table in supabase (currently only has getUserById);
  • Added auth.context.tsx file to handle login and logout and to keep track of userId, isAuthenticated and hasAvatar states (this context is currently sending the whole user model to the localStorage. this may need to be updated in the future for security);
  • Installed toastify library to improve UI communication.
  • Added loading page that waits for context data to be fetched before rendering.

Copy link

netlify bot commented Jan 23, 2025

Deploy Preview for sub-strengths ready!

Name Link
🔨 Latest commit 789f840
🔍 Latest deploy log https://app.netlify.com/sites/sub-strengths/deploys/67923b53a6da83000892833c
😎 Deploy Preview https://deploy-preview-8--sub-strengths.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@thetiagogil thetiagogil changed the base branch from main to optimize-code January 23, 2025 12:51
@thetiagogil thetiagogil force-pushed the add-supabase-connection branch 3 times, most recently from e3d9781 to 3eccaa4 Compare January 23, 2025 14:01
@thetiagogil thetiagogil marked this pull request as draft January 23, 2025 14:43
@thetiagogil thetiagogil force-pushed the add-supabase-connection branch from 3eccaa4 to 95ad727 Compare January 23, 2025 15:08
@thetiagogil thetiagogil marked this pull request as ready for review January 23, 2025 15:08
@thetiagogil thetiagogil force-pushed the add-supabase-connection branch from 95ad727 to a59ae76 Compare January 23, 2025 15:25
@thetiagogil thetiagogil marked this pull request as draft January 23, 2025 17:07
@thetiagogil thetiagogil force-pushed the add-supabase-connection branch 4 times, most recently from dc68bda to d637fe0 Compare January 23, 2025 17:41
@thetiagogil thetiagogil marked this pull request as ready for review January 23, 2025 17:42
@thetiagogil thetiagogil force-pushed the add-supabase-connection branch 3 times, most recently from 65ae4c4 to 02feae5 Compare January 24, 2025 10:21
@thetiagogil thetiagogil force-pushed the optimize-code branch 2 times, most recently from e3b611d to ce75a09 Compare January 24, 2025 10:45
@thetiagogil thetiagogil force-pushed the add-supabase-connection branch from 02feae5 to f2d5f05 Compare January 24, 2025 10:47
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.

1 participant