mirror of
https://github.com/tlsnotary/website.git
synced 2026-01-07 21:24:15 -05:00
Added redirect for old (doc) urls
+ updated TODOs
This commit is contained in:
14
TODO.md
14
TODO.md
@@ -1,19 +1,19 @@
|
||||
TODO:
|
||||
* Design/Styling
|
||||
* ~~drawio/svg cleanup~~
|
||||
* use cases
|
||||
* ~~use cases~~
|
||||
* ~~math in SVGs~~ (Needed an update of local drawio)
|
||||
* social card
|
||||
* review
|
||||
* deployment flow
|
||||
* old links? https://docusaurus.io/docs/api/plugins/@docusaurus/plugin-client-redirects
|
||||
* e.g. https://docs.tlsnotary.org/faq.html -> /docs/faq
|
||||
* ~~deployment flow~~
|
||||
* ~~old links? https://docusaurus.io/docs/api/plugins/@docusaurus/plugin-client-redirects~~
|
||||
* ~~e.g. https://docs.tlsnotary.org/faq.html -> /docs/faq~~
|
||||
* README
|
||||
* Matomo tracking: https://github.com/karser/docusaurus-plugin-matomo/tree/main ?
|
||||
* ~~Matomo tracking: https://github.com/karser/docusaurus-plugin-matomo/tree/main ~~
|
||||
* check links
|
||||
* ~~dark/light theme diagrams~~
|
||||
* rename repo landing-page -> website
|
||||
* archive old documentation website
|
||||
* What to do with drafts etc?
|
||||
* Check Docusaurus warnings
|
||||
* ~~What to do with drafts etc? -> prefix with `_`~~
|
||||
* Check Docusaurus warnings -> Fail build if there are warnings?
|
||||
* Removed current landing page folder "old"
|
||||
@@ -4,6 +4,7 @@ import type * as Preset from '@docusaurus/preset-classic';
|
||||
import remarkMath from 'remark-math';
|
||||
import rehypeKatex from 'rehype-katex';
|
||||
import matomoPlugin from './plugins/matomo-plugin';
|
||||
import { redirects } from './plugins/redirect/index';
|
||||
|
||||
// This runs in Node.js - Don't use client-side code here (browser APIs, JSX...)
|
||||
|
||||
@@ -26,8 +27,10 @@ const config: Config = {
|
||||
onBrokenLinks: 'throw',
|
||||
onBrokenMarkdownLinks: 'warn',
|
||||
|
||||
|
||||
plugins: [matomoPlugin],
|
||||
plugins: [
|
||||
matomoPlugin,
|
||||
['@docusaurus/plugin-client-redirects', { redirects },],
|
||||
],
|
||||
|
||||
// Even if you don't use internationalization, you can use this field to set
|
||||
// useful metadata like html lang. For example, if your site is Chinese, you
|
||||
@@ -97,7 +100,7 @@ const config: Config = {
|
||||
items: [
|
||||
{ to: '/about', label: 'About', position: 'left' },
|
||||
|
||||
{ to: '/use_cases', label: 'Use Cases', position: 'left' },
|
||||
{ to: '/use-cases', label: 'Use Cases', position: 'left' },
|
||||
{
|
||||
type: 'docSidebar',
|
||||
sidebarId: 'tutorialSidebar',
|
||||
|
||||
25
package-lock.json
generated
25
package-lock.json
generated
@@ -9,6 +9,7 @@
|
||||
"version": "0.0.0",
|
||||
"dependencies": {
|
||||
"@docusaurus/core": "3.7.0",
|
||||
"@docusaurus/plugin-client-redirects": "^3.7.0",
|
||||
"@docusaurus/preset-classic": "3.7.0",
|
||||
"@mdx-js/react": "^3.0.0",
|
||||
"clsx": "^2.0.0",
|
||||
@@ -3319,6 +3320,30 @@
|
||||
"react-dom": "*"
|
||||
}
|
||||
},
|
||||
"node_modules/@docusaurus/plugin-client-redirects": {
|
||||
"version": "3.7.0",
|
||||
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-client-redirects/-/plugin-client-redirects-3.7.0.tgz",
|
||||
"integrity": "sha512-6B4XAtE5ZVKOyhPgpgMkb7LwCkN+Hgd4vOnlbwR8nCdTQhLjz8MHbGlwwvZ/cay2SPNRX5KssqKAlcHVZP2m8g==",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@docusaurus/core": "3.7.0",
|
||||
"@docusaurus/logger": "3.7.0",
|
||||
"@docusaurus/utils": "3.7.0",
|
||||
"@docusaurus/utils-common": "3.7.0",
|
||||
"@docusaurus/utils-validation": "3.7.0",
|
||||
"eta": "^2.2.0",
|
||||
"fs-extra": "^11.1.1",
|
||||
"lodash": "^4.17.21",
|
||||
"tslib": "^2.6.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"react": "^18.0.0 || ^19.0.0",
|
||||
"react-dom": "^18.0.0 || ^19.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@docusaurus/plugin-content-blog": {
|
||||
"version": "3.7.0",
|
||||
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-blog/-/plugin-content-blog-3.7.0.tgz",
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@docusaurus/core": "3.7.0",
|
||||
"@docusaurus/plugin-client-redirects": "^3.7.0",
|
||||
"@docusaurus/preset-classic": "3.7.0",
|
||||
"@mdx-js/react": "^3.0.0",
|
||||
"clsx": "^2.0.0",
|
||||
|
||||
27
plugins/redirect/index.ts
Normal file
27
plugins/redirect/index.ts
Normal file
@@ -0,0 +1,27 @@
|
||||
// import type { RedirectItem } from '@docusaurus/plugin-client-redirects/lib/types';
|
||||
|
||||
type RedirectItem = {
|
||||
/** Pathname of the new page we should create */
|
||||
from: string | string[];
|
||||
/** Pathname of an existing Docusaurus page */
|
||||
to: string;
|
||||
};
|
||||
|
||||
export const redirects: RedirectItem[] = [
|
||||
{
|
||||
to: '/docs/faq',
|
||||
from: '/faq', // we do not need to add '/faq.html' because it is already handled by the plugin
|
||||
},
|
||||
{
|
||||
to: '/docs/intro',
|
||||
from: '/intro'
|
||||
},
|
||||
{
|
||||
to: '/docs/motivation',
|
||||
from: '/motivation',
|
||||
},
|
||||
{
|
||||
to: '/docs/quick_start',
|
||||
from: '/quick_start',
|
||||
},
|
||||
];
|
||||
@@ -1,3 +1,4 @@
|
||||
|
||||
---
|
||||
hide_table_of_contents: true
|
||||
---
|
||||
Reference in New Issue
Block a user