https://github.com/manthanank/dev-to-clone-app
Dev.to Clone
https://github.com/manthanank/dev-to-clone-app
angular api bootstrap devto tailwindcss
Last synced: about 1 month ago
JSON representation
Dev.to Clone
- Host: GitHub
- URL: https://github.com/manthanank/dev-to-clone-app
- Owner: manthanank
- Created: 2023-03-13T17:14:34.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2023-03-13T17:14:41.000Z (about 3 years ago)
- Last Synced: 2025-06-14T14:47:32.610Z (12 months ago)
- Topics: angular, api, bootstrap, devto, tailwindcss
- Language: TypeScript
- Homepage: https://dev-to-clone-app.vercel.app/
- Size: 113 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Dev.to Clone
A feature-rich clone of the [Dev.to](https://dev.to) developer community platform, built with **Angular 21** and **Tailwind CSS 4**. It integrates with the official Dev.to API to fetch real articles, tags, and user data.




---
## β¨ Features
- π° **Home Feed** β Browse the latest articles fetched from the Dev.to API
- π **Post Detail** β Full article view with reading time and reaction counts
- π€ **User Profiles** β View any developer's profile and their published articles
- βοΈ **Create Post** β Write and publish new blog posts (authenticated)
- π **Reading List** β Save articles to your personal reading list
- π·οΈ **Tags** β Browse articles by tags/topics
- π **Listings** β Community job listings and classifieds
- ποΈ **Podcasts** β Discover developer podcasts
- π₯ **Videos** β Watch developer video content
- βοΈ **Settings** β Manage account settings and API configuration
- π **Authentication** β Login, register, forgot password, and reset password flows
- π **Dark / Light Mode** β Full theme toggle support
- π± **Responsive Design** β Mobile-first, fully responsive layout
---
## π οΈ Tech Stack
| Technology | Version | Purpose |
| --------------------------------------------------- | ------- | -------------------------- |
| [Angular](https://angular.io/) | 21.x | Frontend framework |
| [TypeScript](https://www.typescriptlang.org/) | 5.9.x | Type-safe JavaScript |
| [Tailwind CSS](https://tailwindcss.com/) | 4.2.x | Utility-first CSS styling |
| [RxJS](https://rxjs.dev/) | 7.8.x | Reactive programming |
| [Dev.to API](https://developers.forem.com/api/) | v1 | Articles, users & tag data |
| [Karma + Jasmine](https://karma-runner.github.io/) | - | Unit testing |
---
## π Project Structure
```text
src/
βββ app/
β βββ core/ # Singleton services & guards
β β βββ auth.service.ts # Authentication logic
β β βββ auth.guard.ts # Route protection
β β βββ api-config.service.ts # API key & URL configuration
β β βββ header/ # App header component
β βββ models/ # TypeScript interfaces
β β βββ post.interface.ts
β β βββ user.interface.ts
β β βββ comment.interface.ts
β βββ pages/ # Route-level page components
β β βββ home/ # Home feed
β β βββ post-detail/ # Article detail page
β β βββ profile/ # User profile page
β β βββ create-post/ # New post editor
β β βββ reading-list/ # Saved articles
β β βββ tags/ # Tags browser
β β βββ listings/ # Job listings
β β βββ podcasts/ # Podcasts page
β β βββ videos/ # Videos page
β β βββ settings/ # Account settings
β β βββ about/ # About page
β β βββ not-found/ # 404 page
β β βββ auth/ # Authentication pages
β β βββ login/
β β βββ register/
β β βββ forgot-password/
β β βββ reset-password/
β βββ shared/ # Reusable components & services
β βββ data.service.ts # Dev.to API data fetching
β βββ theme.service.ts # Dark/light mode toggle
β βββ post-card/ # Reusable post card component
βββ environments/ # Environment configuration
βββ styles.scss # Global styles
```
---
## π Getting Started
### Prerequisites
- [Node.js](https://nodejs.org/) v20 or higher
- [npm](https://www.npmjs.com/) v10 or higher
- [Angular CLI](https://angular.io/cli) v21
### Installation
1. **Clone the repository**
```bash
git clone https://github.com/manthanank/dev-to-clone-app.git
cd dev-to-clone-app
```
2. **Install dependencies**
```bash
npm install
```
3. **Configure the environment** *(optional)*
To use the Dev.to API with your own API key, update `src/environments/environment.ts`:
```ts
export const environment = {
production: false,
apiUrl: 'https://dev.to/api',
apiKey: 'YOUR_DEV_TO_API_KEY' // optional
};
```
> You can also set the API key at runtime via the **Settings** page in the app.
4. **Start the development server**
```bash
npm start
```
Navigate to `http://localhost:4200/`. The app reloads automatically on file changes.
---
## π Available Scripts
| Command | Description |
| ----------------- | ------------------------------------------------ |
| `npm start` | Run the development server at `localhost:4200` |
| `npm run build` | Build the production bundle to `dist/` |
| `npm run watch` | Build in development watch mode |
| `npm test` | Run unit tests via Karma |
---
## π Dev.to API Integration
This app uses the [Forem API v1](https://developers.forem.com/api/) (Dev.to's public API) to fetch real content.
- **Articles** β Fetched via `GET /articles`
- **Article Detail** β Fetched via `GET /articles/{id}`
- **User Profile** β Fetched via `GET /users/{username}`
- **Tags** β Fetched via `GET /tags`
- **Authenticated User** β Fetched via `GET /users/me` (requires API key)
A CORS proxy is configured in `proxy.conf.json` for local development.
---
## π Authentication
Authentication is simulated locally and supports:
- **Email/Password Login** β Creates a local session stored in `localStorage`
- **Registration** β Registers a new user profile locally
- **API Key Login** β Provide a Dev.to API key to authenticate as your real Dev.to account
- **Forgot / Reset Password** β Simulated password reset flow
- **Auth Guard** β Protects the `/new` (Create Post) route from unauthenticated access
---
## πΊοΈ Routes
| Path | Page | Protected |
| ------------------- | --------------- | --------- |
| `/` | Home Feed | No |
| `/post/:id` | Post Detail | No |
| `/user/:username` | User Profile | No |
| `/new` | Create Post | β
Yes |
| `/reading-list` | Reading List | No |
| `/tags` | Tags | No |
| `/about` | About | No |
| `/settings` | Settings | No |
| `/listings` | Listings | No |
| `/podcasts` | Podcasts | No |
| `/videos` | Videos | No |
| `/login` | Login | No |
| `/register` | Register | No |
| `/forgot-password` | Forgot Password | No |
| `/reset-password` | Reset Password | No |
| `/**` | 404 Not Found | No |
---
## π€ Contributing
Contributions are welcome! Please follow these steps:
1. Fork the repository
2. Create a new branch: `git checkout -b feature/your-feature-name`
3. Commit your changes: `git commit -m 'feat: add your feature'`
4. Push to the branch: `git push origin feature/your-feature-name`
5. Open a Pull Request
---
## π License
This project is licensed under the [MIT License](LICENSE).
---
## π Acknowledgements
- [Dev.to](https://dev.to) β For the inspiration and their public API
- [Forem](https://www.forem.com/) β The open-source platform behind Dev.to
- [Angular Team](https://angular.io/) β For the excellent framework