-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
77 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,81 @@ | ||
## Getting Started | ||
|
||
First, run the development server: | ||
This project has been tested with Node.js versions 18 and 20. | ||
|
||
```bash | ||
npm run dev | ||
``` | ||
1. **Setup Environment Variables** | ||
- Create an `.env` file in the root directory of the project. | ||
- Add the following values from the provided gist link: | ||
```bash | ||
POSTGRES_URL="" | ||
POSTGRES_PRISMA_URL="" | ||
POSTGRES_URL_NO_SSL="" | ||
POSTGRES_URL_NON_POOLING="" | ||
POSTGRES_USER="" | ||
POSTGRES_HOST="" | ||
POSTGRES_PASSWORD="" | ||
POSTGRES_DATABASE="" | ||
``` | ||
|
||
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. | ||
execute `npm run seed-db` to populate the database. This step is only necessary if you are using your own database. | ||
|
||
2. **Install Dependencies** | ||
- Run the following command to install the necessary dependencies: | ||
```bash | ||
npm install | ||
``` | ||
|
||
3. **Start the Development Server** | ||
- Launch the development server with the command: | ||
```bash | ||
npm run dev | ||
``` | ||
|
||
4. **Access the Application** | ||
- Open your browser and navigate to [http://localhost:3000](http://localhost:3000) to see the result. | ||
|
||
|
||
## Features | ||
|
||
- **Site-wide Features:** | ||
- Utilizes server-side rendering and react server components(RSC). | ||
- Offers Dark/Light/System Preference mode switcher. | ||
- Includes skeleton loading indicators. | ||
- Implements server actions. | ||
- Responsive UI, mobile menu etc. | ||
- Utilizes kysely query builder for database implementation. | ||
- CI/CD deployments. | ||
- Server side validations as well as client side input validations. | ||
|
||
- **Home Page ("/"):** | ||
- Implements infinite loading | ||
- Displays summaries of blog posts without the full description. | ||
- Users can click to view the full blog post. | ||
|
||
- **Individual Blog Post ("/<blog-post-id>"):** | ||
- Allows users to view the full blog post. | ||
|
||
- **Admin Panel ("/admin"):** | ||
- Enables adding new posts. | ||
- Supports editing existing posts. | ||
- Allows deletion of posts. | ||
|
||
## Tech Stack | ||
|
||
- React, Typescript | ||
- Tailwind CSS (https://tailwindcss.com/) | ||
- Shadcn components (https://ui.shadcn.com/) | ||
- Storybook (https://storybook.js.org/) | ||
- ESLint, Prettier | ||
|
||
## Future Improvements | ||
|
||
- Enhance test coverage. | ||
- Implement user authentication. | ||
- Introduce end-to-end tests. | ||
- More granular error handling. | ||
- Add search feature. | ||
- Show notifications on success or failure. | ||
- Please feel free to create GitHub issues for any feature requests. | ||
|
||
|
||
**Important:** Components located in the `src/components/ui` directory are sourced from [Shadcn components](https://ui.shadcn.com/). |