1
- # Laravel Breadcrumb
2
-
3
- [ ![ Latest Version on Packagist] [ ico-version ]] [ link-packagist ]
4
- [ ![ Software License] [ ico-license ]] ( LICENSE.md )
5
- [ ![ Build Status] [ ico-travis ]] [ link-travis ]
6
- [ ![ Coverage Status] [ ico-scrutinizer ]] [ link-scrutinizer ]
7
- [ ![ Quality Score] [ ico-code-quality ]] [ link-code-quality ]
8
- [ ![ Total Downloads] [ ico-downloads ]] [ link-downloads ]
9
-
1
+ # Breadcrumb for Laravel 5
10
2
11
3
This package provide simple way to implement breadcrumb for your laravel 5 application.
12
4
@@ -18,15 +10,27 @@ Via Composer
18
10
$ composer require mares29/laravel-breadcrumb
19
11
```
20
12
13
+ Laravel 5.5+ automaticly register service provider and set Alias thanks to auto-discovery. With lower laravel version add to ** app.php**
14
+
15
+ ``` php
16
+ 'providers' => [
17
+ \Mares29\Breadcrumb\BreadcrumbServiceProvider::class,
18
+ ]
19
+
20
+ 'aliases' => [
21
+ 'Breadcrumb' => \Mares29\Breadcrumb\Facades\BreadcrumbFacade::class,
22
+ ]
23
+ ```
24
+
21
25
## Usage
22
26
23
- You can use Facade to set breadcrumb links.
27
+ Use Facade to add breadcrumb links.
24
28
25
29
``` php
26
30
Breadcrumb::addLink("link title", "link route");
27
31
```
28
32
29
- You can also add more links
33
+ You can also add more links.
30
34
31
35
``` php
32
36
Breadcrumb::addLink("link title", "link route")
@@ -39,44 +43,23 @@ And finaly render breadcrumb using render method in blade template.
39
43
{!! Breadcrumb::render() !!}
40
44
```
41
45
42
- ## Change log
43
-
44
- Please see [ CHANGELOG] ( CHANGELOG.md ) for more information on what has changed recently.
46
+ By default, first link (home link) is set automaticly with ` config('app.name') ` and links to ` url("/") ` . You can modify this by
45
47
46
- ## Testing
47
-
48
- ``` bash
49
- $ composer test
48
+ ```
49
+ Breadcrumb::setHomeLink("new home link", "/home.html");
50
50
```
51
51
52
- ## Contributing
53
-
54
- Please see [ CONTRIBUTING] ( CONTRIBUTING.md ) and [ CODE_OF_CONDUCT] ( CODE_OF_CONDUCT.md ) for details.
55
-
56
- ## Security
52
+ ** Need to modify breadcrumb html?** Use ` vendor:publish ` command and export breadcrumb view into resources folder.
57
53
58
- If you discover any security related issues, please email
[email protected] instead of using the issue tracker.
54
+ ```
55
+ php artisan vendor:publish --provider="Mares29\Breadcrumb\BreadcrumbServiceProvider"
56
+ ```
59
57
60
58
## Credits
61
59
62
- - [ Karel Mares] [ link-author ]
63
- - [ All Contributors] [ link-contributors ]
60
+ - [ Karel Mares] [ https://github.com/mares29 ]
64
61
65
62
## License
66
63
67
64
The MIT License (MIT). Please see [ License File] ( LICENSE.md ) for more information.
68
65
69
- [ ico-version] : https://img.shields.io/packagist/v/mares29/Laravel Breadcrumb.svg?style=flat-square
70
- [ ico-license ] : https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square
71
- [ ico-travis] : https://img.shields.io/travis/mares29/Laravel Breadcrumb/master.svg?style=flat-square
72
- [ ico-scrutinizer] : https://img.shields.io/scrutinizer/coverage/g/mares29/Laravel Breadcrumb.svg?style=flat-square
73
- [ ico-code-quality] : https://img.shields.io/scrutinizer/g/mares29/Laravel Breadcrumb.svg?style=flat-square
74
- [ ico-downloads] : https://img.shields.io/packagist/dt/mares29/Laravel Breadcrumb.svg?style=flat-square
75
-
76
- [ link-packagist] : https://packagist.org/packages/mares29/Laravel Breadcrumb
77
- [ link-travis] : https://travis-ci.org/mares29/Laravel Breadcrumb
78
- [ link-scrutinizer] : https://scrutinizer-ci.com/g/mares29/Laravel Breadcrumb/code-structure
79
- [ link-code-quality] : https://scrutinizer-ci.com/g/mares29/Laravel Breadcrumb
80
- [ link-downloads] : https://packagist.org/packages/mares29/Laravel Breadcrumb
81
- [ link-author ] : https://github.com/mares29
82
- [ link-contributors ] : ../../contributors
0 commit comments