Skip to content

Commit

Permalink
Migration: frontend changes to redirect to Grafana Docs (#1642)
Browse files Browse the repository at this point in the history
* Remove old versioned pages + logs to discover pages

* Update footer

* Update header menu

* Update homepage

* Guides: add redirect and removed child pages

* Manage Extensions & Integrations

* Examples

* Remove Disruptor and JLib files

* Remove Javascript API pages

* Added AttentionBlockquote

* Update outdated-blockquote.view.js

---------

Co-authored-by: Heitor Tashiro Sergent <[email protected]>
  • Loading branch information
ppcano and heitortsergent authored Jul 16, 2024
1 parent 987fed3 commit 186ea8a
Show file tree
Hide file tree
Showing 678 changed files with 353 additions and 34,826 deletions.
24 changes: 10 additions & 14 deletions gatsby-node.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,19 +176,11 @@ const getPageVersions = (
const topLevelLinks = [
{
label: 'guides',
to: '/',
to: 'https://grafana.com/docs/k6/latest/',
},
{
label: 'JAVASCRIPT API',
to: '/javascript-api/',
submenu: [
{ label: 'k6 API', to: `/javascript-api/` },
{
label: 'xk6-disruptor',
to: `/javascript-api/xk6-disruptor/`,
},
{ label: 'jslib', to: `/javascript-api/jslib/` },
],
to: 'https://grafana.com/docs/k6/latest/javascript-api/',
},
{
label: 'Cloud Docs',
Expand All @@ -203,15 +195,15 @@ const topLevelLinks = [
},
{
label: 'Extensions',
to: '/extensions/',
to: 'https://grafana.com/docs/k6/latest/extensions/',
},
{
label: 'Integrations',
to: '/integrations/',
to: 'https://grafana.com/docs/k6/latest/misc/integrations/',
},
{
label: 'examples',
to: '/examples/',
to: 'https://grafana.com/docs/k6/latest/examples/',
},
];

Expand Down Expand Up @@ -1179,7 +1171,10 @@ async function createDocPages({
reporter,
}),
)
.map((pageProps) => actions.createPage(pageProps));
.map((pageProps) =>
// console.log(pageProps.path);
actions.createPage(pageProps),
);
}

const createRedirects = ({ actions }) => {
Expand Down Expand Up @@ -2099,6 +2094,7 @@ exports.onCreateNode = ({ node, actions }) => {
// Adding default values for some fields and moving them under node.fields
// because that how createNodeField works
if (node.frontmatter) {
// console.log('node slug: ' , node.frontmatter.slug);
createNodeField({
node,
name: 'redirect',
Expand Down
Loading

0 comments on commit 186ea8a

Please sign in to comment.