Skip to content

asmattic/next-supabase-messages

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Full-stack real-time chat

  • Data: @supabase_io (on top of PostgeSQL) for the real-time messages.
  • Front-end: React (CRA)
  • UI library: @chakra_ui

Install

npm install to setup dependencies

Supabase variables

Create a .env file for the Supapase URL and ANON KEY (see env.example)

Setup your Supabase project

The following database table is required:

Field Type
id BIGINT
username VARCHAR
country VARCHAR
text TEXT

SQL query if not using the Supabase interface:

CREATE TABLE messages (
  id bigint GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY,
  username VARCHAR NOT NULL,
  country VARCHAR,
  text TEXT NOT NULL
);

Dev

npm start to run server on port 3000

Build

npm run build to build the react client

Example

'example'

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published