Allow customizing environment detection in EnvironmentIndicatorPlugin #36
No reviewers
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
pxlrbt/filament-environment-indicator!36
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "claude/configurable-environment-gvPgY"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
This PR adds the ability to customize how the environment is detected in the EnvironmentIndicatorPlugin, allowing users to override the default
app()->environment()behavior with a static string or closure.Key Changes
$environmentproperty to store the custom environment valueenvironment(string|Closure $environment)method to configure a custom environment resolvergetEnvironment()method that evaluates the custom environment or falls back toapp()->environment()app()->environment()throughout the plugin to use$plugin->getEnvironment()insteadThanks!