Skip to content

Commit b42c863

Browse files
author
jdv
committed
fixed some stuff
1 parent 40da490 commit b42c863

5 files changed

Lines changed: 67 additions & 73 deletions

File tree

crowdsec-docs/docusaurus.config.ts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { themes } from "prism-react-renderer";
55

66
import tailwindPlugin from "./plugins/tailwind-config";
77
import { ctiApiSidebar, guidesSideBar, remediationSideBar, trackerApiSidebar } from "./sidebarsUnversioned";
8-
import { patternRedirects } from "./src/patternRedirects";
98

109
const extractPreprocessor = require("./plugins/extract-preprocessor");
1110

@@ -339,20 +338,6 @@ const config: Config = {
339338

340339
["./plugins/gtag/index.ts", { trackingID: "G-0TFBMNTDFQ" }],
341340
"./plugins/leadfeeder/index.js",
342-
["@docusaurus/plugin-client-redirects", {
343-
redirects,
344-
createRedirects(existingPath: string) {
345-
for (const { from, to } of patternRedirects) {
346-
// Build a regex from the `to` pattern by replacing capture group refs ($1) with (.+)
347-
const toRegex = new RegExp("^" + to.replace(/\$\d+/g, "(.+)") + "$");
348-
if (toRegex.test(existingPath)) {
349-
// Reverse: produce the old `from` URL from the real path
350-
return [existingPath.replace(toRegex, from.source)];
351-
}
352-
}
353-
return undefined;
354-
},
355-
}],
356341
[
357342
"@signalwire/docusaurus-plugin-llms-txt",
358343
{

0 commit comments

Comments
 (0)