Welcome to the Zario community! We believe in the power of collaboration and appreciate every contribution, from a simple typo fix to a major new feature. This guide will help you get started and ensure a smooth and positive experience.
There are many ways to contribute to the project, and we welcome all of them!
|
🐛 Report Bugs Found something broken? Report it → |
💡 Request Features Have a great idea? Suggest it → |
📖 Improve Docs Found a typo? Submit PR → |
💻 Write Code Ready to get started? Start here → |
Ready to start coding? Here’s how to set up Zario for local development.
-
Fork the Repository Click the "Fork" button at the top right of the main repository page. This creates your own copy of the project.
-
Clone Your Fork Clone your forked repository to your local machine.
git clone https://github.com/<your-username>/zario.git cd zario
Replace
<your-username>with your GitHub username. -
Install Dependencies We use
npmto manage project dependencies.npm install
-
Run the Build The project is written in TypeScript and needs to be compiled into JavaScript.
npm run build
-
Run Tests Make sure everything is working as expected by running the test suite.
npm test
Here's a map of the Zario codebase to help you find your way around.
/
├── docs/ # 📚 Documentation files for the library
├── src/ # TypeScript source code
│ ├── core/ # Core logic: Logger, Formatter, etc.
│ ├── transports/ # Handles log output destinations (Console, File)
│ ├── utils/ # Helper utilities (e.g., color and time formatting)
│ ├── types/ # Shared TypeScript interfaces and type definitions
│ └── index.ts # Main entry point that exports the public API
├── tests/ # ✅ Unit and integration tests
├── examples/ # 💡 Example usage scripts
├── package.json # Project dependencies and scripts
└── tsconfig.json # TypeScript compiler configurationTo keep the codebase consistent and easy to read, please follow these guidelines:
- TypeScript First: All new code should be written in TypeScript with strong typing.
- Code Style: We use ESLint for code linting. Please run
npm run lintbefore committing to ensure your code matches the project's style. - Comments: Write comments for complex logic. Well-documented code is easier for everyone to understand and maintain.
- Tests: All new features and bug fixes must be accompanied by tests. This ensures stability and prevents future regressions.
Ready to share your work? Follow these steps to submit a pull request (PR).
-
Create a Branch: Start from the
mainbranch and create a new, descriptive branch for your changes.# Example for a new feature git checkout -b feat/your-awesome-feature # Example for a bug fix git checkout -b fix/bug-description
-
Commit Your Changes: Make your changes and commit them with a descriptive message. We follow the Conventional Commits specification, which helps us automate releases and generate changelogs.
feat:for new features.fix:for bug fixes.docs:for documentation changes.style:for code style changes (formatting, etc.).refactor:for code refactoring without changing functionality.test:for adding or fixing tests.chore:for build process or auxiliary tool changes.
git commit -m "feat: add support for custom log levels with colors" -
Push to Your Fork:
git push origin feat/your-awesome-feature
-
Create the Pull Request: Open a pull request from your fork's branch to the
mainbranch of the Dev-Dami/zario repository. -
Describe Your PR: Provide a clear title and a detailed description of your changes. If your PR addresses an open issue, link to it (e.g.,
Closes #123).
Once submitted, we'll review your PR, provide feedback, and merge it when it's ready. Thank you for your contribution!
Have questions or want to discuss ideas? Join the conversation on our GitHub Discussions page!
By contributing, you agree that your contributions will be licensed under the MIT License.
