Skip to content

feat(snap-networks-utils): add shared RemoteFeatureFlagProvider - #99

Merged
ulissesferreira merged 3 commits into
mainfrom
WPN-1790-create-feature-flags-provider
Aug 4, 2026
Merged

feat(snap-networks-utils): add shared RemoteFeatureFlagProvider#99
ulissesferreira merged 3 commits into
mainfrom
WPN-1790-create-feature-flags-provider

Conversation

@ulissesferreira

Copy link
Copy Markdown
Contributor

This pull request introduces a new RemoteFeatureFlagProvider utility to the snap-networks-utils package, enabling access to remote feature flags via a messenger interface. The provider is fully tested and integrates with the @metamask/remote-feature-flag-controller package, which is added as a new dependency.

New Remote Feature Flag Provider

  • Added the RemoteFeatureFlagProvider class, which exposes methods to fetch individual or multiple remote feature flag values using an injected messenger. This enables other code to easily query LaunchDarkly/client-config feature flags.
  • Defined supporting types and constants for the provider, including RemoteFeatureFlagProviderMessenger and REMOTE_FEATURE_FLAG_PROVIDER_NAME, to ensure type safety and integration with the messenger system.

Testing

  • Added comprehensive tests for RemoteFeatureFlagProvider, covering both single and multiple flag retrieval, including cases for missing keys and empty input.

Dependency Updates

  • Added @metamask/remote-feature-flag-controller as a new dependency in package.json to support the new provider.## Explanation

References

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

@ulissesferreira
ulissesferreira requested review from a team as code owners August 4, 2026 00:51
@ulissesferreira
ulissesferreira force-pushed the WPN-1790-create-feature-flags-provider branch 3 times, most recently from 901858d to d1b4c93 Compare August 4, 2026 07:24
@ulissesferreira
ulissesferreira force-pushed the WPN-1790-create-feature-flags-provider branch 4 times, most recently from e755556 to 3fe2cc5 Compare August 4, 2026 08:27
@ulissesferreira
ulissesferreira force-pushed the WPN-1790-create-feature-flags-provider branch from 3fe2cc5 to 43ec7ee Compare August 4, 2026 08:37
@ulissesferreira

Copy link
Copy Markdown
Contributor Author

@metamaskbot publish-preview

@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Preview builds have been published. Learn how to use preview builds in other projects.

Expand for full list of packages and versions.
@metamask-previews/bitcoin-wallet-snap@2.0.0-preview-a0892371
@metamask-previews/snap-networks-utils@0.0.0-preview-a0892371
@metamask-previews/tron-wallet-snap@2.0.0-preview-a0892371

@ulissesferreira
ulissesferreira added this pull request to the merge queue Aug 4, 2026
Merged via the queue into main with commit d9cbee8 Aug 4, 2026
46 checks passed
@ulissesferreira
ulissesferreira deleted the WPN-1790-create-feature-flags-provider branch August 4, 2026 10:57
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.

2 participants