Thanks for your interest in contributing to Stringzy! This document provides guidelines and instructions for contributing to the project.
- Bug fixes - Help us solve issues
- New string functions - Add useful string manipulation methods
- Documentation - Improve examples and guides
- Tests - Add test coverage for existing or new features
-
Fork the repository
-
Clone your fork: Remember to replace
YOUR-USERNAMEwith your actual GitHub username.git clone https://github.com/YOUR-USERNAME/stringzy.git
-
Navigate to the project directory:
cd stringzy -
Install dependencies:
npm install
- Create a new branch:
git checkout -b feature/amazing-feature
- Make your changes
- Write tests for new functions
- Keep functions simple and focused
- Follow existing code style
- Update README if adding new functions
- Use 2 spaces for indentation
- Add JSDoc comments for new functions
- Handle edge cases (null, undefined, empty strings)
- Use descriptive function names
Example:
/**
* Converts string to kebab-case
* @param str Input string
* @returns Kebab-case string
*/
function toKebabCase(str: string): string {
if (!str) return '';
return str.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();
}-
Make sure tests pass:
npm test -
Commit your changes:
git commit -m "feat: add some amazing feature" -
Push to the branch
git push origin feature/amazing-feature
-
Create a pull request with:
- Clear description of changes
- Why the change is needed
- Any breaking changes
If you have any questions or need help, feel free to open an issue. We're happy to help!
By contributing, you agree to license your work under the same license as this project.