-
Clone this repository
git clone https://github.com/swayam25/Aero aero cd aero
-
Install dependencies
pnpm i
-
Create an application at the Discord Developer Portal.
-
Create
.env
file from.env.example
in the root directory and fill in the required values.ENV Vars
- Get
DATABASE_URL
from Supabase. - Get
VITE_SUPABASE_URL
andVITE_SUPABASE_KEY
from Supabase API Settings. - Get
JWT_SECRET
by running the following command.pnpm run gen-secret
- Get
DISCORD_CLIENT_ID
andDISCORD_CLIENT_SECRET
from the Discord Developer Portal. - Get
DISCORD_BOT_TOKEN
from the Discord Developer Portal. - Set
YOUTUBE_DL_PATH
to the path ofyoutube-dl
oryt-dlp
executable. You can install it from GitHub Releases (yt-dlp
) or use a package manager. - Set
DOMAIN
to your domain name orhttps://localhost
for local development. The variable is required for production.DOMAIN="https://your-domain.com"
- Get
-
Push the database schema to Supabase.
pnpm run db:push
-
Navigate to Table Editor in Supabase Dashboard and enable RLS for all the tables.
-
Navigate to Authentication > Policies in Supabase Dashboard and create policies for all the tables.
-
Navigate to Database > Publications in Supabase Dashboard. Then click on
supabase_realtime
and enable theplaylist
table. -
Navigate to Table Editor in Supabase Dashboard and enable Realtime for
playlist
table.
Note
Check the Supabase Docs for more information on enabling Realtime.
- Start the app
pnpm run dev
-
Follow steps 1-10 from the installation section.
-
Change
DOMAIN
in.env
file to your domain name.DOMAIN="https://your-domain.com"
Important
DOMAIN
is the URL you will use to access the app.
This dynamically sets ORIGIN
during node build
and configure the Caddy server's domain (for the reverse proxy).
For local development, you can set it to https://localhost
.
Ensure this matches the Redirect URL in the Discord Developer Portal (see step 5 in the installation section).
Check the SvelteKit Docs for more information about the ORIGIN
variable.
- Run docker container (via
docker compose
)docker compose up -d
-
Things to keep in mind
- Follow our commit message convention.
- Write meaningful commit messages.
- Keep the code clean and readable.
- Make sure the app is working as expected.
-
Code Formatting
- Run
pnpm run format
before committing your changes or usePrettier
extension in your code editor. - Make sure to commit error free code. Run
pnpm run check
to check for any errors.
- Run
-
CSS Style Guide (Tailwind CSS)
- Primary Font Color:
slate-50
(No need to add this explicitly, it is already added as global font color in app.css) - Secondary Font Color:
slate-200
- Tertiary Font Color:
slate-400
- Theme Color:
sky-500
- Primary Background Color:
slate-950
(Globally added in app.css) - Secondary Background Color:
slate-900
(For cards/containers) - Tertiary Background Color:
slate-800
(For cards/options on hover) - Card/Container Background Color:
slate-900
(For cards addborder-slate-700
) - For other colors use
<color>-500
as text color and<color>-500/10
as background color on hover (make sure to have bg color asslate-800
/slate-900
/slate-950
before hover). - Border radius:
rounded-lg
(For every possible card/container) - For buttons and links, we strictly use the
<Button />
component.
- Primary Font Color:
-
Z Index Layer System
- Base Layer (
z-0
): Layout components and default content. - Content Layer (
z-10
): Drawer content and elevated cards. - UI Components (
z-50
): Tooltips and popovers. - Modals & Overlays (
z-100
): Dialog and alert popups. - Toast Notifications (
z-2000
): Toast messages usingstyle="z-index: 2000;"
. - Context Menus (
z-[1000]
): Right-click context menu usingz-[1000]
class. - Submenus (
z-[1001]
): Context menu submenus usingz-[1001]
class. - Mobile Drawers: Dynamic
zIndex
prop values:- Player drawer:
zIndex={1000}
(defaultMobileDrawer
componentzIndex
value) - Queue & Lyrics drawer:
zIndex={1100}
- Context menu drawer:
zIndex={1300}
- Player drawer:
- Base Layer (