Open Source Contributions

Contributing

  1. Fork the repository

  2. Create a feature branch

  3. Commit your changes

  4. Push to the branch

  5. Create a Pull Request

Development Guidelines

  1. Code Style

    • Follow the project's ESLint and Prettier configuration

    • Write meaningful commit messages

    • Keep commits focused and atomic

    • Use conventional commits:

      feat: add new feature
      fix: resolve bug
      docs: update documentation
      style: format code
      refactor: improve code structure
      test: add tests
      chore: update dependencies
  2. Testing

    • Write unit tests for new features

    • Ensure all tests pass before submitting PR

    • Include test coverage for critical paths

    • Follow testing best practices:

      // Test component rendering
      it("renders correctly", () => {
        render(<Component />);
        expect(screen.getByText("text")).toBeInTheDocument();
      });
      
      // Test user interactions
      it("handles user input", async () => {
        render(<Component />);
        await userEvent.type(screen.getByRole("textbox"), "input");
        expect(screen.getByText("input")).toBeInTheDocument();
      });
  3. Documentation

    • Update relevant documentation

    • Add JSDoc comments for new functions

    • Include examples for complex features

    • Follow documentation best practices:

      /**
       * Calculates the total price including tax
       * @param {number} price - The base price
       * @param {number} taxRate - The tax rate as a decimal
       * @returns {number} The total price including tax
       * @example
       * const total = calculateTotal(100, 0.1);
       * // Returns 110
       */
      function calculateTotal(price: number, taxRate: number): number {
        return price * (1 + taxRate);
      }

Version History

  • v0.1.0: Initial release

Last updated