8000 Allow useBreadcrumb to control individual BBreadcrumb instances · Issue #2630 · bootstrap-vue-next/bootstrap-vue-next · GitHub
[go: up one dir, main page]

Skip to content
Allow useBreadcrumb to control individual BBreadcrumb instances #2630
Closed
@hackel

Description

@hackel

Clear and concise description of the problem

useBreadcrumb is very useful for controlling a single BBreadcrumb instance on a page, but is not usable if there are multiple BBreadcrumbs. Items added using the composable end up appearing on both sets of breadcrumbs, which is not what the developer wants.

Suggested solution

Allow passing in an id parameter to the composable to control a specific BBreadcrumb instance. When no argument is passed, maintain the existing global behaviour.

const globalBreadcrumb = useBreadcrumb();
const innerBreadcrumb = useBreadcrumb('inner-breadcrumb-1');

Alternative

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0