@docusaurus/plugin-client-redirects 2.4.0 → 3.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/options.d.ts CHANGED
@@ -5,13 +5,13 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  */
7
7
  import type { OptionValidationContext } from '@docusaurus/types';
8
- export declare type RedirectOption = {
8
+ export type RedirectOption = {
9
9
  /** Pathname of an existing Docusaurus page */
10
10
  to: string;
11
11
  /** Pathname of the new page(s) we should create */
12
12
  from: string | string[];
13
13
  };
14
- export declare type PluginOptions = {
14
+ export type PluginOptions = {
15
15
  /** Plugin ID. */
16
16
  id: string;
17
17
  /** The extensions to be removed from the route after redirecting. */
@@ -30,6 +30,6 @@ export declare type PluginOptions = {
30
30
  /** An existing Docusaurus route path */
31
31
  path: string) => string[] | string | null | undefined;
32
32
  };
33
- export declare type Options = Partial<PluginOptions>;
33
+ export type Options = Partial<PluginOptions>;
34
34
  export declare const DEFAULT_OPTIONS: Partial<PluginOptions>;
35
35
  export declare function validateOptions({ validate, options: userOptions, }: OptionValidationContext<Options | undefined, PluginOptions>): PluginOptions;
package/lib/types.d.ts CHANGED
@@ -9,7 +9,7 @@ import type { PluginOptions } from './options';
9
9
  /**
10
10
  * The minimal infos the plugin needs to work
11
11
  */
12
- export declare type PluginContext = Pick<Props, 'outDir' | 'baseUrl' | 'siteConfig'> & {
12
+ export type PluginContext = Pick<Props, 'outDir' | 'baseUrl' | 'siteConfig'> & {
13
13
  options: PluginOptions;
14
14
  relativeRoutesPaths: string[];
15
15
  };
@@ -18,7 +18,7 @@ export declare type PluginContext = Pick<Props, 'outDir' | 'baseUrl' | 'siteConf
18
18
  * /!\ easy to be confused: "from" is the new page we should create,
19
19
  * that redirects to "to": the existing Docusaurus page
20
20
  */
21
- export declare type RedirectItem = {
21
+ export type RedirectItem = {
22
22
  /** Pathname of the new page we should create */
23
23
  from: string;
24
24
  /** Pathname of an existing Docusaurus page */
@@ -5,8 +5,8 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  */
7
7
  import type { PluginContext, RedirectItem } from './types';
8
- export declare type WriteFilesPluginContext = Pick<PluginContext, 'baseUrl' | 'outDir'>;
9
- export declare type RedirectFile = {
8
+ export type WriteFilesPluginContext = Pick<PluginContext, 'baseUrl' | 'outDir'>;
9
+ export type RedirectFile = {
10
10
  fileAbsolutePath: string;
11
11
  fileContent: string;
12
12
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docusaurus/plugin-client-redirects",
3
- "version": "2.4.0",
3
+ "version": "3.0.0-alpha.0",
4
4
  "description": "Client redirects plugin for Docusaurus.",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
@@ -18,25 +18,25 @@
18
18
  },
19
19
  "license": "MIT",
20
20
  "dependencies": {
21
- "@docusaurus/core": "2.4.0",
22
- "@docusaurus/logger": "2.4.0",
23
- "@docusaurus/utils": "2.4.0",
24
- "@docusaurus/utils-common": "2.4.0",
25
- "@docusaurus/utils-validation": "2.4.0",
26
- "eta": "^2.0.0",
27
- "fs-extra": "^10.1.0",
21
+ "@docusaurus/core": "3.0.0-alpha.0",
22
+ "@docusaurus/logger": "3.0.0-alpha.0",
23
+ "@docusaurus/utils": "3.0.0-alpha.0",
24
+ "@docusaurus/utils-common": "3.0.0-alpha.0",
25
+ "@docusaurus/utils-validation": "3.0.0-alpha.0",
26
+ "eta": "^2.0.1",
27
+ "fs-extra": "^11.1.0",
28
28
  "lodash": "^4.17.21",
29
- "tslib": "^2.4.0"
29
+ "tslib": "^2.5.0"
30
30
  },
31
31
  "devDependencies": {
32
- "@docusaurus/types": "2.4.0"
32
+ "@docusaurus/types": "3.0.0-alpha.0"
33
33
  },
34
34
  "peerDependencies": {
35
- "react": "^16.8.4 || ^17.0.0",
36
- "react-dom": "^16.8.4 || ^17.0.0"
35
+ "react": "^18.0.0",
36
+ "react-dom": "^18.0.0"
37
37
  },
38
38
  "engines": {
39
39
  "node": ">=16.14"
40
40
  },
41
- "gitHead": "898b85ef134cc43bf3b1209aad0ca8cdcfb214c5"
41
+ "gitHead": "7327f7ff880ed97ad7855744e59c9c55d467a950"
42
42
  }