Cypher Chat v2 is a modern, real-time chat application designed for secure and private communication, built with a robust TypeScript backend and a dynamic JavaScript/HTML/CSS frontend.
A glimpse of the Cypher Chat user interface.
- 🔒 End-to-End Encryption (Planned): Secure your conversations with advanced cryptographic techniques to ensure privacy.
- ⚡ Real-time Messaging: Experience instant message delivery and seamless communication with WebSocket technology.
- 👤 User Authentication & Profiles: Manage user accounts securely with robust authentication and personalized user profiles.
- 🖼️ Rich Media Support: Share images, videos, and other files directly within your chats (planned).
- 🚀 Scalable Architecture: Built with a modular backend and frontend, ready to scale for growing user bases.
Follow these steps to get Cypher Chat v2 up and running on your local machine.
Ensure you have the following installed:
- Node.js (LTS version recommended)
- npm or Yarn package manager
- Git
-
Clone the Repository:
Start by cloning the project repository to your local machine:
git clone https://github.com/Pantkartik/Cypher_Chat_version_2.git cd Cypher_Chat_version_2 -
Install Backend Dependencies:
Navigate into the
Backenddirectory and install its dependencies:cd Backend npm install # or yarn install
-
Configure Backend Environment (Optional):
If your backend requires specific environment variables (e.g., for database connection, secret keys), create a
.envfile in theBackenddirectory based on a provided.env.example(if available).cp .env.example .env # Open .env and configure your variables -
Install Frontend Dependencies:
Navigate into the
Frontenddirectory and install its dependencies:cd ../Frontend # Go back to root, then enter Frontend npm install # or yarn install
-
Start the Backend Server:
From the
Backenddirectory, start the server:cd ../Backend npm start # or npm run dev if using a dev script
The backend server will typically run on
http://localhost:3000(or another port as configured). -
Start the Frontend Application:
From the
Frontenddirectory, launch the frontend:cd ../Frontend npm start # or npm run dev
The frontend application will usually be accessible at
http://localhost:5173(or another port).
Your Cypher Chat v2 application should now be running!
Once installed, you can access the application through your web browser.
- Open in Browser: Navigate to
http://localhost:5173(or your configured frontend port) in your web browser. - Register/Login: Create a new account or log in with existing credentials.
- Start Chatting: Begin a new conversation or join an existing one to experience real-time messaging.
This is a conceptual example of how the frontend might connect to the backend WebSocket server:5
// Frontend (e.g., in a JavaScript or TypeScript file)
import { io } from 'socket.io-client';
const socket = io('http://localhost:3000'); // Connect to your backend WebSocket server
socket.on('connect', () => {
console.log('Connected to chat server!');
// Emit a message
socket.emit('sendMessage', {
sender: 'Pantkartik',
message: 'Hello, Cypher Chat!',
timestamp: new Date().toISOString()
});
});
socket.on('receiveMessage', (data) => {
console.log('New message:', data.message, 'from', data.sender);
// Update UI with the new message
});
socket.on('disconnect', () => {
console.log('Disconnected from chat server.');
});
Example of a user interacting with the chat interface.
Cypher Chat v2 is continuously evolving. Here's a glimpse of what's planned:
- Version 1.1.0:
- Implement end-to-end encryption for private messages.
- Add group chat functionality.
- Introduce rich media sharing (images, videos).
- Version 1.2.0:
- Develop push notifications for new messages.
- Integrate user presence indicators (online/offline).
- Implement message reactions and replies.
- Enhance UI/UX for a more intuitive and modern feel.
- Optimize backend performance and scalability.
- Improve error handling and logging across the application.
- Expand test coverage for both frontend and backend.
We welcome contributions to Cypher Chat v2! To ensure a smooth collaboration process, please follow these guidelines:
- Adhere to the ESLint configuration and Prettier formatting used in the project.
- Write clear, concise, and well-commented code.
- Ensure all new features or bug fixes include appropriate unit and integration tests.
- Use descriptive branch names:
feature/your-feature-namefor new features.bugfix/issue-descriptionfor bug fixes.chore/task-descriptionfor maintenance tasks (e.g., dependency updates).
- Fork the repository and create your feature/bugfix branch from
main. - Ensure your code passes all existing tests and add new tests for your changes.
- Commit your changes with clear, descriptive commit messages.
- Submit a pull request to the
mainbranch of this repository. - Provide a detailed description of your changes in the PR, including any relevant issue numbers.
- All new features must be accompanied by unit tests.
- Bug fixes should include a test that reproduces the bug and then passes with the fix.
- Run
npm test(oryarn test) in bothBackendandFrontenddirectories before submitting a PR.
This project currently has no specified license.
This means that by default, all rights are reserved by the copyright holder, Pantkartik. You may not reproduce, distribute, or create derivative works from this project without explicit permission.
Copyright (c) 2024 Pantkartik. All rights reserved.
For any inquiries regarding licensing or usage, please contact the main contributor.