Skip to content

Contributing

Thank you for your interest in contributing to Media Viewer!

For complete contributing guidelines, please see the CONTRIBUTING.md file in the root of the repository.

Overview

The main contributing guide covers:

  • Setting up your development environment
  • Code style guidelines
  • Testing requirements
  • Pull request process
  • Commit message conventions
  • Issue reporting templates

Before Opening A PR

Use the root guide for the full workflow, but these are the checks most contributors need day to day:

# Recommended all-in-one pre-PR check
make pr-check

# Default frontend browser E2E lane
make frontend-test-e2e

# Separate visual regression lane
make frontend-test-e2e-visual

# Refresh visual snapshot baselines after intentional UI changes
make frontend-test-e2e-visual-baselines

# Refresh documentation screenshots only when docs/images/ assets need updating
make frontend-test-e2e-docs-screenshots

Notes:

  • make pr-check runs backend lint/test/race checks for Go-related changes and frontend ESLint/Prettier/svelte-check/unit/smoke checks for frontend changes.
  • make pr-check-fix runs the same flow but uses Go lint autofix before the backend test steps.
  • make pr-check does not run broader Playwright coverage outside smoke, visual regression, docs screenshot generation, or performance lanes.
  • The default frontend E2E lane excludes @performance and @docs-screenshots specs.
  • Visual regression is a separate lane that compares Playwright screenshot baselines stored as PNGs in frontend/e2e/snapshots/.
  • Docs screenshot generation writes PNG assets directly to docs/images/.
  • See testing.md for the complete testing matrix and command reference.

PR Checklist

Use this short checklist before opening or updating a pull request:

  • Run make pr-check for the standard local PR gate. It covers backend lint/test/race checks plus frontend check/unit/integration/smoke when matching files changed.
  • If you want Go lint issues auto-fixed before rerunning the same local PR gate, use make pr-check-fix.
  • If the PR changes frontend flows outside the smoke subset, also run make frontend-test-e2e or a focused target such as make frontend-test-e2e-file <spec> or make frontend-test-e2e-module <tag>.
  • If the PR intentionally changes visuals, run make frontend-test-e2e-visual. If the new output is expected, regenerate baselines with make frontend-test-e2e-visual-baselines and include the updated artifacts in the PR.
  • If the PR refreshes docs imagery, run make frontend-test-e2e-docs-screenshots and include the updated docs/images/ assets in the PR.
  • If the PR touches performance-sensitive frontend flows, run the relevant make frontend-test-e2e-performance* lane manually.

Documentation

If you're specifically interested in contributing to documentation:

  1. Documentation is written in Markdown
  2. Source files are in the docs/ directory
  3. Built with MkDocs Material theme
  4. Follow the MkDocs documentation for formatting

To preview documentation changes locally:

make docs-serve

Then open http://localhost:8000 in your browser.

Getting Help

If you have questions about contributing:

We appreciate your contributions!