File tree 2 files changed +15
-6
lines changed
2 files changed +15
-6
lines changed Original file line number Diff line number Diff line change @@ -17,15 +17,18 @@ block content
17
17
ul.nav.nav-list
18
18
each link in sidebar
19
19
if link .url
20
- if locals .rootSidebar
21
- li
22
- a( href ='/' + link .url , class =locals .pageSegment == link.url && 'active' ) = link .name
20
+ - var linkHref
21
+ if link .external
22
+ - linkHref = link .url
23
+ else if locals .rootSidebar
24
+ - linkHref = ' /' + link .url
23
25
else
24
- li
25
- a( href ='/' + page + '/' + link .url , class =locals .pageSegment == link.url && 'active' ) = link .name
26
+ - linkHref = ' /' + page + ' /' + link .url
27
+ li
28
+ a( href =linkHref, class =locals .pageSegment == link.url && 'active' ) = link .name
26
29
else
27
30
li.nav-header
28
31
if link .icon
29
32
i( class =link .icon )
30
33
span= link .name
31
- include blocks/advertisements
34
+ include blocks/advertisements
Original file line number Diff line number Diff line change @@ -99,6 +99,12 @@ module.exports = function (grunt) {
99
99
sidebars [ 0 ] = getSidebarSection ( '## API' , 'icon-cog' ) ;
100
100
sidebars [ 1 ] = getSidebarSection ( '### Other' ) ;
101
101
102
+ sidebars [ 1 ] . push ( {
103
+ name : 'Github' ,
104
+ url : 'https://github.com/gruntjs/' ,
105
+ external : true
106
+ } ) ;
107
+
102
108
names . forEach ( function ( name ) {
103
109
var src = base + name + '.md' ,
104
110
dest = 'build/api/' + name . toLowerCase ( ) + '.html' ;
You can’t perform that action at this time.
0 commit comments