From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server-vie001.gnuweeb.org X-Spam-Level: X-Spam-Status: No, score=-1.2 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,URIBL_DBL_BLOCKED_OPENDNS, URIBL_ZEN_BLOCKED_OPENDNS autolearn=ham autolearn_force=no version=3.4.6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1737247218; bh=RF0CXi3On08ywwGhFPYwckiEQv4xuTw49RT0W+AG8Gs=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Transfer-Encoding:Message-ID:Date:From: Reply-To:Subject:To:Cc:In-Reply-To:References:Resent-Date: Resent-From:Resent-To:Resent-Cc:User-Agent:Content-Type: Content-Transfer-Encoding; b=bFbOx97cWYlVCtyvVh6R9m/vSOqGsDJ3t7K82GZ9VK4/JZ1k/7S5ioo4LMXSx4eb7 3OQrhc0n/DuPJmVdGlkp+HJlAnHBLJi1a4hteR93xeaisPDPcd2LsWectf4U+Ma6X3 Iw+H0bDfgEIciLFzD6eFiaV1GW0Eh0boEWZCm5kF08FaUVa5/Z1ZgobQHZUPukTfWz B4njpcuDXCdUMm9lT6wRUHoEwWXUqWpvTnvZO3FmgzArUHtn88wUQO/JT0rulCySIe Jlj3LkRcsSR3kwX+rG4dvJrCE9FSb04waZty/4Pui/S8ZttVqQ/CIGmhA+9YKU3LVZ 4oz0wn/k5jGRw== Received: from localhost.localdomain (unknown [101.128.125.239]) by server-vie001.gnuweeb.org (Postfix) with ESMTPSA id 38CD42061C22; Sun, 19 Jan 2025 00:40:17 +0000 (UTC) From: Muhammad Rizki To: Ammar Faizi Cc: Muhammad Rizki , Alviro Iskandar Setiawan , Dwiky Rizky Ananditya , GNU/Weeb Mailing List Subject: [PATCH v1 16/16] chore: update README.md Date: Sun, 19 Jan 2025 07:39:09 +0700 Message-ID: <20250119003911.1183-17-kiizuha@gnuweeb.org> X-Mailer: git-send-email 2.45.2.windows.1 In-Reply-To: <20250119003911.1183-1-kiizuha@gnuweeb.org> References: <20250119003911.1183-1-kiizuha@gnuweeb.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: This update tells guide how to install and contribute to this project. Signed-off-by: Muhammad Rizki --- README.md | 117 ++++++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 95 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index b5b2950..7b63918 100644 --- a/README.md +++ b/README.md @@ -1,38 +1,111 @@ -# sv +

+ GNU/Weeb Mail +

-Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli). +

+ Table of Contents +

-## Creating a project +- [Requirements](#requirements) +- [How to Run](#how-to-run) +- [How to Build](#how-to-build) +- [Code Standards](#code-standards) +- [How to Develop or Contribute](#how-to-develop) -If you're seeing this, you've probably already done this step. Congrats! +

+ Requirements +

-```bash -# create a new project in the current directory -npx sv create +- **NodeJS** version 18+,strongly recommended to use version 20+ as this project developed using **NodeJS** version 20+ + [Download](https://nodejs.org/en/download) +- **TypeScript** version 5, no need to download in your OS as this project will install the TypeScript only inside this project. +- Code Editor, of course, we recommend using your favorite IDE, for example, [VS Code](https://code.visualstudio.com/download). +- Svelte 5 Runes knowledge. -# create a new project in my-app -npx sv create my-app +

+ How to Run +

+ +```sh +# install all dependencies before running this project +npm i +npm run dev ``` -## Developing +

+ How to Build +

+ +```sh +# install all dependencies before building this project +npm i +npm run build +``` -Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server: +After build, the `dist` folder will be created, copy them to your own server, for example, [nginx](https://nginx.org/en/download.html). -```bash -npm run dev +

+Code Standards +

-# or start the server and open the app in a new browser tab -npm run dev -- --open -``` +We use `LF` for each End of Line style and add empty newline for every End of File, you must setting all that in your IDE before contributing on this project. -## Building +

+How to Develop or Contribute +

-To create a production version of your app: +

Framework

-```bash -npm run build +If you are new to **SvelteKit** using the **Svelte 5 Runes**, we recommend to learn the framework first, you can learn it [here](https://learn.svelte.dev) or just [read the docs](https://svelte.dev/docs/kit/introduction). + +

Base Components

+ +We used [**shadcn-svelte**](https://www.shadcn-svelte.com/) for the base components, we strongly recommended to use it for now, if you want to add components, just go [here](https://www.shadcn-svelte.com/docs/components/accordion). +This is how you add **shadcn-svelte** component + +```sh +npx shadcn-svelte@latest add ``` -You can preview the production build with `npm run preview`. +After installed **shadcn-svelte** component, it will generated in [$lib/components/ui](./src/lib/components/ui/), if you want to have a small edit. + +

Custom Components

+ +If you want to create your own custom components you can create it in [$lib/components/customs](./src/lib/components/customs/). + +

Static Files

+ +All static files were stored in [./static/](./static/). + +

Page Routes

+ +All pages are created in [./src/routes](./src/routes/) and all protected routes (login required) are created in [./src/routes/(protected)](<./src/routes/(protected)/>). + +

Hooks Functions

+ +All hooks are created in [$lib/hooks](./src/lib/hooks/). + +

Form Schemas

+ +All form schemas are created in [$lib/schemas](./src/lib/schemas/). + +

Constants

+ +All constants data are created in [$constants](./src/lib/constants/). + +

Typings

+ +All types are created in [$typings](./src/lib/typings/). + +

Utilities

+ +All util or helper functions are created in [$utils](./src/lib/utilities/). + +

Styling

+ +If you want to create styles or CSS that only affects inside its page or component just write it inside that file, +if you want to create styles or CSS that affects globally you can write it in [./src/app.css](./src/app.css). + +

Aliases

-> To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment. +You may add some import aliases, you can edit it in [svelte.config.js](./svelte.config.js), we used `$` as import alias, you must follow our standards to remain consistency. -- Muhammad Rizki