Guide for contributing to the CLINK payment plugin. ## How to Contribute ### Reporting Bugs 1. Check [existing issues](https://github.com/WoompaLoompa/medusa-clink/issues) 2. Use **Bug Report** template 3. Include: - Medusa version - Plugin version - Steps to reproduce - Logs ### Suggesting Features 1. Check [discussions](https://github.com/WoompaLoompa/medusa-clink/discussions) 2. Use **Feature Request** template 3. Describe use case ### Pull Requests 1. Fork repository 2. Create feature branch 3. Make changes 4. Add tests 5. Submit PR --- ## Development Setup ### Prerequisites - Node.js 18+ - npm or yarn - Git ### Setup ```bash # Clone git clone https://github.com/WoompaLoompa/medusa-clink.git # Install npm install # Test npm test # Build npm run build ``` --- ## Code Style - TypeScript strict mode - ESLint for linting - Prettier for formatting ### Naming Conventions - Files: `kebab-case.ts` - Classes: `PascalCase` - Functions: `camelCase` - Constants: `UPPER_SNAKE_CASE` --- ## Testing ### Run Tests ```bash # All tests npm test # Watch mode npm run test:watch # Coverage npm run test:coverage ``` ### Write Tests ```typescript describe("Feature", () => { it("should do something", async () => { // Arrange const input = { /* ... */ } // Act const result = await service.method(input) // Assert expect(result).toEqual(expected) }) }) ``` --- ## Commits Follow [Conventional Commits](https://www.conventionalcommits.org/): - `feat:` new feature - `fix:` bug fix - `docs:` documentation - `test:` adding tests Examples: ``` feat: add Kraken support fix: handle expired invoice docs: update merchant guide ``` --- ## Pull Request Checklist - [ ] Code follows style guidelines - [ ] Self-review completed - [ ] Tests added/updated - [ ] Documentation updated - [ ] No console.log statements - [ ] All tests pass --- ## Getting Help - [Discussions](https://github.com/WoompaLoompa/medusa-clink/discussions) - [CLINK Protocol](https://clinkme.dev) - [Medusa Docs](https://docs.medusajs.com/)