-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Logs UI] "View in logs" shared component/hook/function #82635
Comments
Pinging @elastic/logs-metrics-ui (Team:logs-metrics-ui) |
@elastic/kibana-platform we want to export components and other stuff from the For example, the |
Are these shared component stateless, or are they 'preconfigured'/'connected' components that are automatically wired to If they are not, the best solution would be to extract them to a separate 'bundle' plugin and then import them in both plugins (like how we are using the |
@pgayvallet in some cases stateless but in many cases we will want to share stateful components and helpers. How do we do that without creating circular dependencies? |
In that case, I see two options:
|
Yes okay, these were the two options we talked about ourselves but wanted to see if there was any recommended way we weren't thinking about. Thanks! |
Following the spirit of the
<LogStream />
component, I think it could be interesting to expose a hook or component that generates links to the logs app. Right now several plugins have functionality to link to the logs app but each plugin implements its own solution.The Logs plugin can export a shared function/hook that generates a URL, or a shared, opinionated component with a button.
The API for these components will mimic the same arguments as the actual
<LogStream />
component, to maximize consistency.Having a controlled and unified way to generate links will give us later freedom to modify the URL any way we want if we need to.
The text was updated successfully, but these errors were encountered: