Skip to content

Latest commit

 

History

History
135 lines (92 loc) · 3.57 KB

File metadata and controls

135 lines (92 loc) · 3.57 KB

Contributing to Stream Deck SDK

Thank you for your interest in contributing to the Stream Deck SDK! We welcome contributions from the community and are grateful for your support.

Table of Contents

Code of Conduct

By participating in this project, you agree to maintain a respectful and inclusive environment for all contributors. Please be considerate and professional in all interactions.

Contributing

Before submitting a pull request, we kindly ask that you first create an issue to discuss your proposed changes. This helps ensure that your contribution aligns with the project's goals, and allows maintainers and the community to provide feedback early in the process.

Feature Requests

We welcome feature requests; to propose a new feature:

  1. Search existing issues to see if it has already been requested.
  2. Create a new issue if needed, including:
    • The problem it solves.
    • How you envision it working.
    • Any alternatives you've considered.
    • Whether you're willing to contribute the implementation.

Fixing Issues

If you find a bug or have a problem with the SDK:

  1. Search existing issues to see if it has already been reported.
  2. Create a new issue if needed.

AI Policy

We welcome contributions that leverage AI tools as assistants in the development process. However, we require that:

  • You must fully understand all code you submit.
  • You are responsible for the quality and correctness of your code.
  • Automated or low-quality AI pull requests will be rejected.

Development

Prerequisites

  • Node.js 24 or higher - we recommend using a version manager such as nvm (macOS) or nvm-windows (Windows).
  • pnpm - available from pnpm.io.

Installation

  1. Install dependencies:

    pnpm install
    
  2. Build the project:

    pnpm build
    
  3. Start development environment:

    pnpm dev
    

Testing

We use Vitest for testing. Please ensure all tests pass before submitting your changes.

Running Tests

  • Run all tests:

    pnpm test
    
  • Run tests in watch mode:

    pnpm test:watch
    
  • Run tests with coverage:

    pnpm test:coverage
    

Writing Tests

  • Place test files in __tests__ directories next to the code they test
  • Name test files with the .test.ts pattern (e.g., action.test.ts)
  • Write clear, descriptive test names that explain what is being tested
  • Aim for high test coverage, especially for public APIs and critical functionality

Code Style

This project uses ESLint and Prettier to maintain consistent code style.

Linting

  • Check for linting errors:

    pnpm lint
  • Auto-fix linting and formatting issues:

    pnpm lint:fix

Style Guidelines

  • Use TypeScript for all code.
  • Follow existing patterns and conventions in the codebase.
  • Write clear, self-documenting code with meaningful variable and function names.
  • Add JSDoc comments for public APIs.
  • Keep functions focused and concise.