Skip to content

Commit d83df12

Browse files
Revert "Migration: frontend changes to redirect to Grafana Docs" (#1655)
This reverts commit 186ea8a.
1 parent 416d1d7 commit d83df12

File tree

678 files changed

+34826
-353
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

678 files changed

+34826
-353
lines changed

gatsby-node.js

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -176,11 +176,19 @@ const getPageVersions = (
176176
const topLevelLinks = [
177177
{
178178
label: 'guides',
179-
to: 'https://grafana.com/docs/k6/latest/',
179+
to: '/',
180180
},
181181
{
182182
label: 'JAVASCRIPT API',
183-
to: 'https://grafana.com/docs/k6/latest/javascript-api/',
183+
to: '/javascript-api/',
184+
submenu: [
185+
{ label: 'k6 API', to: `/javascript-api/` },
186+
{
187+
label: 'xk6-disruptor',
188+
to: `/javascript-api/xk6-disruptor/`,
189+
},
190+
{ label: 'jslib', to: `/javascript-api/jslib/` },
191+
],
184192
},
185193
{
186194
label: 'Cloud Docs',
@@ -195,15 +203,15 @@ const topLevelLinks = [
195203
},
196204
{
197205
label: 'Extensions',
198-
to: 'https://grafana.com/docs/k6/latest/extensions/',
206+
to: '/extensions/',
199207
},
200208
{
201209
label: 'Integrations',
202-
to: 'https://grafana.com/docs/k6/latest/misc/integrations/',
210+
to: '/integrations/',
203211
},
204212
{
205213
label: 'examples',
206-
to: 'https://grafana.com/docs/k6/latest/examples/',
214+
to: '/examples/',
207215
},
208216
];
209217

@@ -1171,10 +1179,7 @@ async function createDocPages({
11711179
reporter,
11721180
}),
11731181
)
1174-
.map((pageProps) =>
1175-
// console.log(pageProps.path);
1176-
actions.createPage(pageProps),
1177-
);
1182+
.map((pageProps) => actions.createPage(pageProps));
11781183
}
11791184

11801185
const createRedirects = ({ actions }) => {
@@ -2094,7 +2099,6 @@ exports.onCreateNode = ({ node, actions }) => {
20942099
// Adding default values for some fields and moving them under node.fields
20952100
// because that how createNodeField works
20962101
if (node.frontmatter) {
2097-
// console.log('node slug: ' , node.frontmatter.slug);
20982102
createNodeField({
20992103
node,
21002104
name: 'redirect',

0 commit comments

Comments
 (0)