Skip to content

Conversation

@pranjal-jately-ld
Copy link
Contributor

@pranjal-jately-ld pranjal-jately-ld commented Nov 12, 2025

Description

This PR adds support for an internal LaunchDarkly client within the toolbar package, enabling toolbar-specific feature flags and analytics tracking. The internal client is separate from the user's application client and can be optionally configured via environment variables.

What does this PR do?

  • Adds InternalClientProvider component to manage the toolbar's internal LaunchDarkly client
  • Implements createToolbarFlagFunction for type-safe access to toolbar feature flags
  • Adds support for configurable LaunchDarkly service URLs (base, stream, events) via environment variables
  • Updates build configuration to inject environment variables at build time
  • Adds comprehensive documentation for setting up the internal client configuration
  • Includes unit tests for the new provider and flag function

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • 📚 Documentation (changes to documentation only)
  • 🔧 Refactor (code change that neither fixes a bug nor adds a feature)
  • 🎨 Style (formatting, missing semicolons, etc; no production code change)
  • Performance (code change that improves performance)
  • Test (adding missing tests, refactoring tests; no production code change)
  • 🔨 Chore (updating grunt tasks, build process, etc; no production code change)

Screenshots/Videos


- Introduced InternalClientProvider to manage the internal LaunchDarkly
client for toolbar features and analytics.
- Added support for loading environment variables with the TOOLBAR_
prefix in the toolbar configuration files.
- Introduced a new vite-env.d.ts file to define environment variable
types for better TypeScript support.
…ternal client

- Added support for TOOLBAR_INTERNAL_BASE_URL, TOOLBAR_INTERNAL_STREAM_URL,
and TOOLBAR_INTERNAL_EVENTS_URL in the toolbar configuration.
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