Skip to content

refactor(snap-network-utils): rename RemoteFeatureFlagProvider to RemoteFeatureFlagsProvider - #104

Merged
ulissesferreira merged 1 commit into
mainfrom
WPN-1790-rename-remote-feature-flags-provider-to-plural
Aug 4, 2026
Merged

refactor(snap-network-utils): rename RemoteFeatureFlagProvider to RemoteFeatureFlagsProvider#104
ulissesferreira merged 1 commit into
mainfrom
WPN-1790-rename-remote-feature-flags-provider-to-plural

Conversation

@ulissesferreira

@ulissesferreira ulissesferreira commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Explanation

RemoteFeatureFlagProvider was introduced in #99 and exported in #102 as a shared utility for reading remote feature flags from Core via RemoteFeatureFlagController:getState. The singular Flag naming was inconsistent with the controller (RemoteFeatureFlagController) and our other pluralized provider exports (e.g. AssetsProvider), and it reads awkwardly for a class that returns multiple flags via getFeatureFlags.

This PR renames the provider and its related symbols to use Flags (plural):

Before After
RemoteFeatureFlagProvider RemoteFeatureFlagsProvider
RemoteFeatureFlagProviderMessenger RemoteFeatureFlagsProviderMessenger
REMOTE_FEATURE_FLAG_PROVIDER_NAME REMOTE_FEATURE_FLAGS_PROVIDER_NAME

Source files are renamed accordingly (RemoteFeatureFlagsProvider.ts, RemoteFeatureFlagsProvider.test.ts). Package exports in src/index.ts are updated to match.

Note: The Core controller action and types remain RemoteFeatureFlagController / RemoteFeatureFlagController:getState (singular Flag) — only the snap-networks-utils provider namespace and exports change.

No consumers in this repo or downstream snaps currently import the old singular names, so this is a low-risk rename ahead of broader adoption.

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 a review from a team as a code owner August 4, 2026 12:49
@ulissesferreira ulissesferreira changed the title refactor(snap-network-utils): rename RemoteFeatureFlagProvider to `… refactor(snap-network-utils): rename RemoteFeatureFlagProvider to RemoteFeatureFlagsProvider Aug 4, 2026
@ulissesferreira
ulissesferreira force-pushed the WPN-1790-rename-remote-feature-flags-provider-to-plural branch from dc32809 to 36b3048 Compare August 4, 2026 12:52

@taran-a taran-a left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ulissesferreira
ulissesferreira added this pull request to the merge queue Aug 4, 2026
Merged via the queue into main with commit 153d9e2 Aug 4, 2026
46 checks passed
@ulissesferreira
ulissesferreira deleted the WPN-1790-rename-remote-feature-flags-provider-to-plural branch August 4, 2026 13:01
@ulissesferreira ulissesferreira mentioned this pull request Aug 4, 2026
4 tasks
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