Skip to content

feat: add mergeSnapshotOptions utility to @percy/sdk-utils#2213

Open
rishigupta1599 wants to merge 1 commit intomasterfrom
feat/add-merge-snapshot-options-utility
Open

feat: add mergeSnapshotOptions utility to @percy/sdk-utils#2213
rishigupta1599 wants to merge 1 commit intomasterfrom
feat/add-merge-snapshot-options-utility

Conversation

@rishigupta1599
Copy link
Copy Markdown
Contributor

Summary

  • Adds mergeSnapshotOptions(options) to @percy/sdk-utils that centralizes the .percy.yml config merge logic
  • Merges percy.config.snapshot options with per-snapshot options (snapshot options take priority)
  • This was previously duplicated as inline code across all 10 Percy JS SDKs

Test plan

  • Unit tests added for mergeSnapshotOptions covering: merge behavior, priority, undefined config, no options
  • All 5 new tests pass
  • Once published, all SDK PRs will bump @percy/cli version to use this utility

🤖 Generated with Claude Code

Centralizes the .percy.yml config merge logic that was duplicated across all 10 Percy JS SDKs.
The function merges percy.config.snapshot options with per-snapshot options, giving snapshot options priority.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@rishigupta1599 rishigupta1599 requested a review from a team as a code owner May 5, 2026 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant