- Data: @supabase_io (on top of PostgeSQL) for the real-time messages.
- Front-end: React (CRA)
- UI library: @chakra_ui
npm install
to setup dependencies
Create a .env
file for the Supapase URL and ANON KEY (see env.example)
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
);
npm start
to run server on port 3000
npm run build
to build the react client