
Build a full-stack blog with reactjs and Supabase, enabling user authentication, post creation, and viewing with routing, state management, and deployment on Vercel.
Install NodeJS, then create a new React app named Block, open the terminal, and run npm start to view the app on localhost:3000 in VS Code.
Bootstrap Template: https://startbootstrap.com/theme/clean-blog
Create the navigation and footer as separate React components in a layout folder, export them, and import into app.js to render the top nav and bottom footer.
Organize the app structure by creating pages, auth, and post folders under source, and adding home.js, contact.js, add boost.js, login.js, signup.js, and a single post page.
This quickstart guides you through creating a Supabase project, exploring database, authentication, storage, and functions, and connecting a React app using the public API key.
Connect Supabase with React to link your app to the server by installing supabase-js, creating a .env file with the base URL and anon key, and initializing the Supabase client.
Install react-router-dom and set up BrowserRouter, Routes, and Route to enable navigation between home, about, post, and authentication pages. Connect the home component to the root path /.
Set up authentication in a React app using Supabase, configure test mode email confirmation, and wire login and signup routes with React Router DOM to create a functional authentication template.
Create an auth context in a React and Supabase app to manage sign up, sign in, sign out, and auth state changes, providing a user session across the app.
Build a signup page that captures email and password with React refs, calls the auth context signup, handles errors, and navigates to the home page.
Learn to convert the sign-up layout into a sign-in page by duplicating the sign-up code, adjusting imports, input refs, and the sign-in function, and handling errors and user state.
Add a sign out button to the navigation bar, wire it to the auth context signOut function, and navigate home after sign out with React Router.
Implement sign out using auth context and conditional navigation with React Router. Show login or sign out buttons based on user state and refresh the page to reflect changes.
Create a blog post form in a React.js with Supabase project, defining a blog table with title, description, content, and image, and post data to the server.
Add post button triggers an asynchronous add block function that collects title, description, and content from the input. It creates a UUID, uploads the data to Supabase, and navigates home.
Upload an image to a public blog image bucket in Supabase storage. Configure policies for insert, update, select, and delete; and implement an onchange uploadImage function to upload the file.
Develop the image upload flow by creating a git url function to fetch the public url from the blog image bucket in Supabase and update the post with the image.
Fetch and display all posts from Supabase server on the home page by querying the Block table, map data to show titles and descriptions, enabling viewing posts with error handling.
Implement a single post view in a ReactJS app using Supabase. Pass the post ID via URL, fetch data with useEffect and useParams, and render title, description, content, and image.
Optimize a full-stack blog site by refining the navigation bar, linking the home page as my blog, and implementing conditional post creation with auth context in React Router; prepare deployment.
Deploy your full-stack ReactJS with Supabase app using Vercel, connect GitHub, deploy to a new global domain, and showcase the site in your portfolio.
In This course you will learn how to Build a full-stack website using React and Supabase, and deploy it on the web using Vercel,
we will build a Blog using react and connect it with Supabase.
we will use React library to help us improve the website. be ready to discover Supabase and the services that can boost your development process, and get a good Knowledge of how to connect your backend with your front-end code.
I will be happy to answer any questions you need while taking this course.
We will cover in this course:
- Create React app and set up the app structure.
- Create a Supabase account and creating a database
- Connecting Supabase with React using Supabase library
- Convert HTML -CSS JavaScript to ReactJS
- Using ( useState - useEffect - useContext .. ) on ReactJs
- Using Supabase services ( Database - Storage - Api ...)
- Using React Router to route between pages and pass data.
- Creating add post page and inserting it to supabase table
- Crating bucket to store the Image and adding Police inside Supabase with a public URL.
- Deploy your app
... and more
Who this course is for:
developers.
Anyone who is creating dynamic websites.
Those working in React, Supabse who want to learn and develop their skills.