Skip to content

ng8-breadcrumb is an Angular 8 module generating breadcrumbs based on the routing state.

License

Notifications You must be signed in to change notification settings

allahyar/ng8-breadcrumb

Repository files navigation

ng8-breadcrumb

NPM
Downloads Version

Installation

ng8-breadcrumb is available on NPM

$ npm install ng8-breadcrumb --save

Setup & Usage

Once the module has been installed, you need to include Ng8BreadcrumbModule into your root module:

import {Ng8BreadcrumbModule} from 'ng8-breadcrumb';
...
@NgModule({
  imports: [
    ...
    Ng8BreadcrumbModule.forRoot({
        prefix: 'Home' // default 'false'
    }),
    ...
  ],
  ...
})
export class AppModule {}

& Anywhere template component :

<ng8-breadcrumb></ng8-breadcrumb>

Use the service :

 constructor(private _breadcrumb: BreadcrumbService) {
    _breadcrumb.store('id', 'iPhone x');
  }

And finally route configuration:

{
        path: '...',
        ...
        data: { breadcrumb: 'YOUR TEXT' },
        ...
}

License

ng8-breadcrumb is released under MIT license.

Author

Allahyar

About

ng8-breadcrumb is an Angular 8 module generating breadcrumbs based on the routing state.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published