@@ -85,7 +85,12 @@ module.exports = {
85
85
} ,
86
86
plugins : {
87
87
title : "Plugin" ,
88
- content : ( ) => require . context ( './loaders/page-loader!./src/content/plugins' , false , / ^ \. \/ .* \. m d $ / ) ,
88
+ content : ( ) => {
89
+ return combineContexts (
90
+ require . context ( './loaders/page-loader!./src/content/plugins' , false , / ^ \. \/ .* \. m d $ / ) ,
91
+ require . context ( './loaders/page-loader!./generated/plugins' , false , / ^ \. \/ .* \. m d $ / )
92
+ ) ;
93
+ } ,
89
94
url : ( { sectionName, fileName } ) => `/${ sectionName } /${ fileName } /` ,
90
95
transform : ( pages ) => {
91
96
return _ . sortBy ( pages , ( page ) => page . file . sort )
@@ -95,18 +100,10 @@ module.exports = {
95
100
loaders : {
96
101
title : "Loaders" ,
97
102
content : ( ) => {
98
- const content = require . context (
99
- './loaders/page-loader!./src/content/loaders' ,
100
- false ,
101
- / ^ \. \/ .* \. m d $ /
103
+ return combineContexts (
104
+ require . context ( './loaders/page-loader!./src/content/loaders' , false , / ^ \. \/ .* \. m d $ / ) ,
105
+ require . context ( './loaders/page-loader!./generated/loaders' , false , / ^ \. \/ .* \. m d $ / )
102
106
) ;
103
- const generated = require . context (
104
- './loaders/page-loader!./generated/loaders' ,
105
- false ,
106
- / ^ \. \/ .* \. m d $ /
107
- ) ;
108
-
109
- return combineContexts ( content , generated ) ;
110
107
} ,
111
108
url : ( { sectionName, fileName } ) => `/${ sectionName } /${ fileName } /` ,
112
109
layout : ( ) => require ( './src/components/Page/Page.jsx' ) . default
@@ -120,7 +117,7 @@ module.exports = {
120
117
'code-splitting-async' : '/guides/code-splitting' ,
121
118
'code-splitting-css' : '/guides/code-splitting' ,
122
119
'code-splitting-libraries' : '/guides/code-splitting' ,
123
- 'why-webpack' : '/guides/ comparison' ,
120
+ 'why-webpack' : '/comparison' ,
124
121
'production-build' : '/guides/production'
125
122
} ,
126
123
transform : ( pages ) => {
0 commit comments