@jpmorganchase/mosaic-types 0.1.0-beta.5 → 0.1.0-beta.52

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.
@@ -0,0 +1,11 @@
1
+ /**
2
+ * [[`ContentProps`]] specifies the page source/content
3
+ */
4
+ export interface ContentProps {
5
+ /** Page source, which will be page type specific */
6
+ source?: Record<string, unknown>;
7
+ /** Page type */
8
+ type?: string;
9
+ /** Raw page content, includes markdown and frontmatter */
10
+ raw?: string;
11
+ }
@@ -1,13 +1,8 @@
1
- /// <reference types="node" />
2
- import type { DirectoryJSON, IRealpathOptions, IMkdirOptions, IReaddirOptions, TData, TMode } from 'memfs/lib/volume';
3
- import type { TDataOut } from 'memfs/lib/encoding';
4
- import type Dirent from 'memfs/lib/Dirent';
5
- import type Stats from 'memfs/lib/Stats';
6
- import type { TStatNumber } from 'memfs/lib/Stats';
7
- import type { IStatOptions } from 'memfs/lib/volume';
8
- import type { PathLike, symlink } from 'fs';
9
- import type { Page } from './Page';
1
+ /// <reference types="node" resolution-mode="require"/>
10
2
  import type { Options, Pattern, Entry } from 'fast-glob';
3
+ import type { DirectoryJSON, IRealpathOptions, IMkdirOptions, IReaddirOptions, IStatOptions, TData, TMode, TDataOut, Dirent, Stats, TStatNumber } from 'memfs';
4
+ import type { PathLike, symlink } from 'fs';
5
+ import type { Page } from './Page.js';
11
6
  /**
12
7
  * This is the core underlying filesystem, which directly interfaces with a memfs Volume to mutate the filesystem
13
8
  */
package/dist/Mode.d.ts ADDED
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Mosaic mode dictates how content is loaded
3
+ *
4
+ * `active`
5
+ * In this mode, content is pulled from configured data sources and updates in real-time.
6
+ * After content is updated, Mosaic plugins create an enhanced, in-memory file object, representing the content
7
+ *
8
+ * `snapshot-file`
9
+ * In this mode, previously created snapshot files are loaded from a local directory.
10
+ *
11
+ * `snapshot-s3`
12
+ * In this mode, previously created snapshot files are loaded from an S3 bucket.
13
+ *
14
+ * (A snapshot is an immutable/persisted copy of `active` content, created separately)
15
+ */
16
+ export declare type MosaicMode = 'active' | 'snapshot-file' | 'snapshot-s3';
package/dist/Page.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * `Page` is a type, which at a minimum has a `fullPath`, but can also contain metadata and `content`
3
3
  */
4
- export declare type Page<AdditionalProps = {}> = {
4
+ export declare type Page = {
5
5
  fullPath: string;
6
6
  title?: string;
7
7
  /**
@@ -17,4 +17,4 @@ export declare type Page<AdditionalProps = {}> = {
17
17
  lastModified?: Date;
18
18
  type?: string;
19
19
  content?: string;
20
- } & Record<string, unknown> & AdditionalProps;
20
+ };
package/dist/Plugin.d.ts CHANGED
@@ -1,16 +1,40 @@
1
- import type { Page } from './Page';
2
- import type { MutableData } from './MutableData';
3
- import type { PluginModuleDefinition } from './PluginModuleDefinition';
4
- import type { ImmutableData } from './MutableData';
5
- import type { IUnionVolume, IVolumeImmutable, IVolumeMutable, IVolumePartiallyMutable } from './Volume';
6
- import type { Serialiser } from './Serialiser';
7
- export declare type LoadedPlugin = Partial<Plugin> & PluginModuleDefinition;
1
+ import type { IUnionVolume, IVolumeImmutable, IVolumeMutable, IVolumePartiallyMutable } from './Volume.js';
2
+ import type { PluginModuleDefinition } from './index.js';
3
+ import type { Serialiser } from './Serialiser.js';
4
+ import type { Page } from './Page.js';
5
+ import type { MutableData, ImmutableData } from './MutableData.js';
6
+ export declare type LoadedPlugin = Partial<Plugin<Page>> & PluginModuleDefinition;
7
+ export declare type LifecycleMethod = keyof Plugin<Page>;
8
+ export declare type PluginErrorDescriptor = {
9
+ /**
10
+ * The plugin lifecycle method running when the error occurred
11
+ */
12
+ lifecycleMethod: string;
13
+ /**
14
+ * The path to the loaded plugin module
15
+ */
16
+ pluginModulePath: string;
17
+ /**
18
+ * The name of the plugin
19
+ */
20
+ pluginName: string;
21
+ /**
22
+ * The name of the error
23
+ */
24
+ name: string;
25
+ /**
26
+ * The path of the file that triggered the plugin error
27
+ */
28
+ fullPath?: string;
29
+ };
30
+ export declare type PluginErrors = Array<PluginErrorDescriptor>;
31
+ export declare type TrackPluginErrorCallback = (errors: Array<PluginErrorDescriptor>, lifecycleMethod: string) => void;
8
32
  /**
9
33
  * Plugins are lifecycle-based hooks that are called on every source at different stages.
10
34
  * Consumers will never need to invoke a lifecycle method; but for technical clarity - when a lifecycle method is called,
11
35
  * it will trigger `pluginRunner` which executes it on every source automatically.
12
36
  */
13
- export declare type Plugin<ConfigData = {}, PluginOptions = {}, GlobalConfigData = ConfigData> = {
37
+ export declare type Plugin<TPage extends Page = Page, TOptions = Record<string, unknown>, ConfigData = Record<string, unknown>, GlobalConfigData = ConfigData> = {
14
38
  /**
15
39
  * Plugin lifecycle method that triggers inside child processes.
16
40
  * The first lifecycle hook to trigger after receiving pages from a source. The pages can safely be mutated and will be reflected in the final
@@ -18,30 +42,34 @@ export declare type Plugin<ConfigData = {}, PluginOptions = {}, GlobalConfigData
18
42
  * @param pages Array of pages from the source
19
43
  * @param param.serialiser A matching `Serialiser` for serialising/deserialising pages when reading/writing to the filesystem
20
44
  * @param param.config A mutable object for sharing data with other lifecycle phases of all plugins for this source (including in the main thread) in this plugin
45
+ * @param param.namespace The namespace of the source running the plugin
21
46
  * @param options The options passed in when declaring the plugin
22
47
  * @returns {Promise<Page[]>} Must re-return an array of `Page` objects, modified or not
23
48
  */
24
- $afterSource?(pages: Page[], {}: {
25
- serialiser: Serialiser;
49
+ $afterSource?: (pages: TPage[], helpers: {
50
+ serialiser: Serialiser<TPage>;
26
51
  config: MutableData<ConfigData>;
27
52
  pageExtensions: string[];
28
53
  ignorePages: string[];
29
- }, options?: Pick<PluginModuleDefinition, 'options'> & PluginOptions): Promise<Page[]>;
54
+ namespace: string;
55
+ }, options?: TOptions) => Promise<Array<TPage>>;
30
56
  /**
31
57
  * Plugin lifecycle method that triggers inside child processes.
32
58
  * Calls after a filesystem has been built up from the source pages.
33
59
  * @param mutableFilesystem Mutable virtual filesystem instance with all of this source's pages inside (and symlinks applied)
34
60
  * @param param.serialiser A matching `Serialiser` for serialising/deserialising pages when reading/writing to the filesystem
35
61
  * @param param.config A mutable object for sharing data with other lifecycle phases of all plugins for this source (including in the main thread) in this plugin
62
+ * @param param.namespace The namespace of the source running the plugin
36
63
  * @param options The options passed in when declaring the plugin
37
64
  * @returns {void} No return expected
38
65
  */
39
- $beforeSend?(mutableFilesystem: IVolumePartiallyMutable, {}: {
40
- serialiser: Serialiser;
66
+ $beforeSend?: (mutableFilesystem: IVolumePartiallyMutable, helpers: {
67
+ serialiser: Serialiser<TPage>;
41
68
  pageExtensions: string[];
42
69
  ignorePages: string[];
43
70
  config: MutableData<ConfigData>;
44
- }, options?: Pick<PluginModuleDefinition, 'options'> & PluginOptions): Promise<void>;
71
+ namespace: string;
72
+ }, options?: TOptions) => Promise<void>;
45
73
  /**
46
74
  * Plugin lifecycle method that triggers inside the main process.
47
75
  * Calls after the filesystem and symlinks have been reconstructed due to a change to the current source. This happens in the main thread.
@@ -56,18 +84,20 @@ export declare type Plugin<ConfigData = {}, PluginOptions = {}, GlobalConfigData
56
84
  * @param param.globalConfig An immutable object for reading data from other lifecycle phases of all plugins. Shared across all sources.
57
85
  * @param param.sharedFilesystem Mutable filesystem instance independent of any sources. Useful for global pages, like sitemaps
58
86
  * @param param.globalFilesystem Immutable union filesystem instance with all source's pages (and symlinks applied)
87
+ * @param param.namespace The namespace of the source running the plugin
59
88
  * @param options The options passed in when declaring the plugin
60
89
  * @returns {void} No return expected
61
90
  */
62
- afterUpdate?(mutableFilesystem: IVolumePartiallyMutable, {}: {
63
- serialiser: Serialiser;
91
+ afterUpdate?: (mutableFilesystem: IVolumePartiallyMutable, helpers: {
92
+ serialiser: Serialiser<TPage>;
64
93
  config: ImmutableData<ConfigData>;
65
94
  globalFilesystem: IUnionVolume;
66
95
  sharedFilesystem: IVolumeMutable;
67
96
  globalConfig: ImmutableData<GlobalConfigData>;
68
97
  pageExtensions: string[];
69
98
  ignorePages: string[];
70
- }, options?: Pick<PluginModuleDefinition, 'options'> & PluginOptions): Promise<void>;
99
+ namespace: string;
100
+ }, options?: TOptions) => Promise<void>;
71
101
  /**
72
102
  * Plugin lifecycle method that triggers inside the main process everytime ANY source emits new pages.
73
103
  * This method should return a boolean that will indicate if this source should clear page caches.
@@ -77,15 +107,36 @@ export declare type Plugin<ConfigData = {}, PluginOptions = {}, GlobalConfigData
77
107
  * @param param.config An immutable object for reading data from other lifecycle phases of all plugins for this source in the child process for this plugin
78
108
  * @param param.serialiser A matching `Serialiser` for serialising/deserialising pages when reading/writing to the filesystem
79
109
  * @param param.globalFilesystem Immutable union filesystem instance with all source's pages (and symlinks applied)
110
+ * @param param.namespace The namespace of the source running the plugin
111
+ * @param options The options passed in when declaring the plugin
112
+ * @returns {Promise<boolean>} A boolean indicating whether to clear the cache for this source
113
+ */
114
+ shouldClearCache?: (updatedSourceFilesystem: IVolumeImmutable, helpers: {
115
+ serialiser: Serialiser<TPage>;
116
+ config: ImmutableData<ConfigData>;
117
+ globalFilesystem: IUnionVolume;
118
+ pageExtensions: string[];
119
+ ignorePages: string[];
120
+ namespace: string;
121
+ }, options?: TOptions) => Promise<boolean>;
122
+ /**
123
+ * Plugin lifecycle method that triggers inside the main process everytime ANY source emits new pages.
124
+ * This method should return a boolean that will indicate if this source should force other namespace sources to re-run afterUpdate.
125
+ * Returning `undefined`, false or no value, will result in no update being triggered for namespace sources
126
+ * @param updatedSourceFilesystem Immutable filesystem for the source that changed
127
+ * @param param.config An immutable object for reading data from other lifecycle phases of all plugins for this source in the child process for this plugin
128
+ * @param param.serialiser A matching `Serialiser` for serialising/deserialising pages when reading/writing to the filesystem
129
+ * @param param.globalFilesystem Immutable union filesystem instance with all source's pages (and symlinks applied)
130
+ * @param param.namespace The namespace of the source running the plugin
80
131
  * @param options The options passed in when declaring the plugin
81
132
  * @returns {Promise<boolean>} A boolean indicating whether to clear the cache for this source
82
133
  */
83
- shouldClearCache?(updatedSourceFilesystem: IVolumeImmutable, {}: {
84
- serialiser: Serialiser;
134
+ shouldUpdateNamespaceSources?: (updatedSourceFilesystem: IVolumeImmutable, helpers: {
135
+ serialiser: Serialiser<TPage>;
85
136
  config: ImmutableData<ConfigData>;
86
137
  globalFilesystem: IUnionVolume;
87
138
  pageExtensions: string[];
88
139
  ignorePages: string[];
89
- }, options?: Pick<PluginModuleDefinition, 'options'> & PluginOptions): Promise<boolean>;
140
+ namespace: string;
141
+ }, options?: TOptions) => Promise<boolean>;
90
142
  };
91
- export declare type LifecycleMethod = keyof Plugin;
@@ -1,26 +1,26 @@
1
- import type { TDataOut } from 'memfs/lib/encoding';
2
- import type { Page } from './Page';
3
- import type { SerialiserModuleDefinition } from './SerialiserModuleDefinition';
1
+ import type { TDataOut } from 'memfs';
2
+ import type { SerialiserModuleDefinition } from './index.js';
3
+ import type { Page } from './Page.js';
4
4
  /**
5
- * Serialisers are a form of plugin that tells PullDocs how to turn a file from/to a storable form for the filesystem
5
+ * Serialisers are a form of plugin that tells Mosaic how to turn a file from/to a storable form for the filesystem
6
6
  * or a `Page` object.
7
7
  * For technical clarity - when a parser method is called, it will trigger `parserRunner` which checks the `fullPath` against
8
- * the `test` option that was passed in the PullDocs config file, to find a suitable parser.
8
+ * the `test` option that was passed in the Mosaic config file, to find a suitable parser.
9
9
  */
10
- export declare type Serialiser = {
10
+ export declare type Serialiser<TPage extends Page = Page> = {
11
11
  /**
12
12
  * Method to turn a raw page (e.g. an MDX file) into a `Page` object
13
13
  * @param fullPath Route on virtual disk (should be full fullPath, not an alias)
14
14
  * @param page Page in string or buffer form (i.e. an MDX page with frontmatter or a JSON file as a string)
15
15
  * @returns Page object in the `Page` format
16
16
  */
17
- deserialise: (fullPath: string, page: TDataOut) => Promise<Page>;
17
+ deserialise: (fullPath: string, page: TDataOut) => Promise<TPage>;
18
18
  /**
19
19
  * Method to load a raw page from disk (e.g. an MDX file) and return into a `Page` object
20
20
  * @param fullPath Route on virtual disk (should be full fullPath, not an alias)
21
21
  * @param page Page in `Page` form
22
22
  * @returns Page content
23
23
  */
24
- serialise: (fullPath: string, page: Page) => Promise<TDataOut>;
24
+ serialise: (fullPath: string, page: TPage) => Promise<TDataOut>;
25
25
  };
26
26
  export declare type LoadedSerialiser = Serialiser & SerialiserModuleDefinition;
@@ -0,0 +1,22 @@
1
+ export declare type JWT = {
2
+ exp: number;
3
+ UserID?: string;
4
+ JPMCIdentifier?: string;
5
+ UID?: string;
6
+ EmployeeCorporateID?: string;
7
+ CostCenter?: string;
8
+ Country?: string;
9
+ CountryCode?: string;
10
+ Department?: string;
11
+ DisplayName?: string;
12
+ Email?: string;
13
+ EmployeeType?: string;
14
+ FirstName?: string;
15
+ LastName?: string;
16
+ LOB?: string;
17
+ LocationCode?: string;
18
+ };
19
+ export declare type Session<TUserProfile> = {
20
+ isLoggedIn: boolean;
21
+ user?: TUserProfile;
22
+ };
package/dist/Source.d.ts CHANGED
@@ -1,9 +1,11 @@
1
1
  import type { Observable } from 'rxjs';
2
- import type { Serialiser } from './Serialiser';
3
- import type { Page } from './Page';
2
+ import type { Serialiser } from './Serialiser.js';
3
+ import type { Page } from './Page.js';
4
+ import { SourceSchedule } from './index.js';
4
5
  export declare type Source<Options = {}> = {
5
- create(options: Options, { serialiser, pageExtensions }: {
6
+ create(options: Options, { serialiser, pageExtensions, schedule }: {
6
7
  pageExtensions: string[];
7
8
  serialiser: Serialiser;
9
+ schedule: SourceSchedule;
8
10
  }): Observable<Page[]>;
9
11
  };
@@ -0,0 +1,13 @@
1
+ export declare type SourceWorkflowAction<TSourceOptions, TOptions> = (sendWorkflowProgressMessage: SendSourceWorkflowMessage, sourceOptions: TSourceOptions, workflowOptions: TOptions, ...args: any[]) => Promise<unknown>;
2
+ export declare type SourceWorkflow<TSourceOptions = unknown, TOptions = unknown> = {
3
+ name: string;
4
+ options?: TOptions;
5
+ action: SourceWorkflowAction<TSourceOptions, TOptions>;
6
+ };
7
+ export declare type SourceWorkflowMessageStatus = 'SUCCESS' | 'ERROR' | 'IN_PROGRESS' | 'COMPLETE';
8
+ export declare type SendSourceWorkflowMessage = (message: any, status: SourceWorkflowMessageStatus) => void;
9
+ export declare type SourceWorkflowMessageEvent = {
10
+ status: SourceWorkflowMessageStatus;
11
+ message: any;
12
+ channel?: string;
13
+ };
package/dist/Volume.d.ts CHANGED
@@ -1,10 +1,5 @@
1
- /// <reference types="node" />
2
- import type { DirectoryJSON, IRealpathOptions, IMkdirOptions, IReaddirOptions, TData, TMode } from 'memfs/lib/volume';
3
- import type { TDataOut } from 'memfs/lib/encoding';
4
- import type Dirent from 'memfs/lib/Dirent';
5
- import type Stats from 'memfs/lib/Stats';
6
- import type { TStatNumber } from 'memfs/lib/Stats';
7
- import type { IStatOptions } from 'memfs/lib/volume';
1
+ /// <reference types="node" resolution-mode="require"/>
2
+ import type { DirectoryJSON, IRealpathOptions, IMkdirOptions, IReaddirOptions, IStatOptions, TData, TMode, TDataOut, Dirent, Stats, TStatNumber } from 'memfs';
8
3
  import type { PathLike, symlink } from 'fs';
9
4
  import type { Options, Pattern, Entry } from 'fast-glob';
10
5
  /**
@@ -45,7 +40,7 @@ export interface IVolumePartiallyMutable extends Omit<IVolume, 'reset' | 'fromJS
45
40
  __internal_do_not_use_addReadFileHook(hook: (filepath: PathLike, fileData: TDataOut) => Promise<TDataOut>): void;
46
41
  }
47
42
  export interface IUnionVolume extends Omit<IVolumeImmutable, 'promises'> {
48
- promises: Pick<IVolumeImmutable, 'promises'> & {
43
+ promises: Omit<IVolumeImmutable['promises'], 'readFile'> & {
49
44
  /**
50
45
  * Reads a file
51
46
  * @param file Path
@@ -1,6 +1,4 @@
1
- import type { SerialiserModuleDefinition } from './SerialiserModuleDefinition';
2
- import type { PluginModuleDefinition } from './PluginModuleDefinition';
3
- import type { SourceModuleDefinition } from './SourceModuleDefinition';
1
+ import type { SerialiserModuleDefinition, PluginModuleDefinition, SourceModuleDefinition, SourceSchedule } from './index.js';
4
2
  export declare type WorkerData<Options = {}> = {
5
3
  options: Options & Pick<PluginModuleDefinition, 'options'> & Pick<SourceModuleDefinition, 'options'> & {
6
4
  pageExtensions: string[];
@@ -12,4 +10,5 @@ export declare type WorkerData<Options = {}> = {
12
10
  plugins: PluginModuleDefinition[];
13
11
  serialisers: SerialiserModuleDefinition[];
14
12
  modulePath: string;
13
+ schedule: SourceSchedule;
15
14
  };
package/dist/index.d.ts CHANGED
@@ -1,13 +1,15 @@
1
- export * from './IFileAccess';
2
- export * from './Meta';
3
- export * from './MutableData';
4
- export * from './Page';
5
- export * from './Plugin';
6
- export * from './PluginModuleDefinition';
7
- export * from './PullDocsConfig';
8
- export * from './Serialiser';
9
- export * from './SerialiserModuleDefinition';
10
- export * from './Source';
11
- export * from './SourceModuleDefinition';
12
- export * from './Volume';
13
- export * from './WorkerData';
1
+ import type { SerialiserModuleDefinition, MosaicConfig, PluginModuleDefinition, SourceModuleDefinition, SourceWorkflow, SourceSchedule } from '@jpmorganchase/mosaic-schemas';
2
+ export * from './Content.js';
3
+ export * from './IFileAccess.js';
4
+ export * from './Meta.js';
5
+ export * from './MutableData.js';
6
+ export * from './Page.js';
7
+ export * from './Plugin.js';
8
+ export * from './Serialiser.js';
9
+ export * from './Source.js';
10
+ export * from './Volume.js';
11
+ export * from './WorkerData.js';
12
+ export * from './Mode.js';
13
+ export * from './Session.js';
14
+ export * from './SourceWorkflow.js';
15
+ export { SerialiserModuleDefinition, MosaicConfig, PluginModuleDefinition, SourceModuleDefinition, SourceWorkflow, SourceSchedule };
package/package.json CHANGED
@@ -1,25 +1,36 @@
1
1
  {
2
2
  "name": "@jpmorganchase/mosaic-types",
3
- "version": "0.1.0-beta.5",
4
- "author": "",
3
+ "version": "0.1.0-beta.52",
5
4
  "description": "Mosaic BitBucket source for core file system",
6
5
  "license": "Apache-2.0",
6
+ "author": "",
7
+ "type": "module",
7
8
  "types": "./dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./dist/index.d.ts"
12
+ }
13
+ },
8
14
  "engines": {
9
- "node": ">= 12.0.0"
15
+ "node": ">=16.10.0 || >=18.0.0"
10
16
  },
11
17
  "repository": {
12
18
  "type": "git",
13
- "url": "git@github.com:jpmorganchase/mosaic.git"
19
+ "url": "git@github.com:jpmorganchase/mosaic.git",
20
+ "directory": "packages/types"
14
21
  },
15
22
  "files": [
16
23
  "dist"
17
24
  ],
18
25
  "scripts": {
19
26
  "build": "tsc",
20
- "clean": "rm -fr dist"
27
+ "clean": "rm -fr dist",
28
+ "lint": "eslint --ignore-pattern \"**/__tests__/**\""
21
29
  },
22
30
  "devDependencies": {
23
- "rxjs": "^7.5.5"
31
+ "@jpmorganchase/mosaic-schemas": "^0.1.0-beta.52",
32
+ "memfs": "^3.4.12",
33
+ "rxjs": "^7.5.5",
34
+ "zod": "^3.22.3"
24
35
  }
25
36
  }
package/CHANGELOG.md DELETED
@@ -1,37 +0,0 @@
1
- # @jpmorganchase/mosaic-types
2
-
3
- ## 0.1.0-beta.5
4
-
5
- ### Patch Changes
6
-
7
- - 61a246c: This releases add support for generate / build and serve snapshots
8
-
9
- ## 0.1.0-beta.4
10
-
11
- ### Patch Changes
12
-
13
- - bd285df: added dist to package.json
14
-
15
- ## 0.1.0-beta.3
16
-
17
- ### Patch Changes
18
-
19
- - 457df5e: switch to public package
20
-
21
- ## 0.1.0-beta.2
22
-
23
- ### Patch Changes
24
-
25
- - e1bbbe7: Initial release of Mosaic Core file-system.
26
-
27
- Mosaic is a content aggregating service which pulls content from heterogeneous data sources.
28
-
29
- - 4b2bc51: pipped to 0.1.0-beta.1 for publishing to NPM
30
-
31
- ## 0.1.0
32
-
33
- ### Patch Changes
34
-
35
- - e1bbbe7: Initial release of Mosaic Core file-system.
36
-
37
- Mosaic is a content aggregating service which pulls content from heterogeneous data sources.
@@ -1,19 +0,0 @@
1
- export interface PluginModuleDefinition {
2
- /**
3
- * Options to pass to the plugin lifecycle methods.
4
- */
5
- options: Record<string, unknown>;
6
- /**
7
- * The importance of this plugin. This highest number plugin will be run first
8
- */
9
- priority?: number;
10
- /**
11
- * Exclude this plugin when running `mosaic build`
12
- */
13
- runTimeOnly?: boolean;
14
- /**
15
- * Path to the JS file for this plugin (can either export a `default` module with lifecycle methods,
16
- * or export the methods individually)
17
- */
18
- modulePath: string;
19
- }
@@ -1,10 +0,0 @@
1
- import type { PluginModuleDefinition } from './PluginModuleDefinition';
2
- import type { SerialiserModuleDefinition } from './SerialiserModuleDefinition';
3
- import type { SourceModuleDefinition } from './SourceModuleDefinition';
4
- export interface PullDocsConfig {
5
- pageExtensions: Array<string>;
6
- ignorePages?: Array<string>;
7
- serialisers: Array<SerialiserModuleDefinition>;
8
- plugins: Array<PluginModuleDefinition>;
9
- sources: Array<SourceModuleDefinition>;
10
- }
@@ -1,4 +0,0 @@
1
- import type { PluginModuleDefinition } from './PluginModuleDefinition';
2
- export declare type SerialiserModuleDefinition = PluginModuleDefinition & {
3
- filter: RegExp;
4
- };
@@ -1,5 +0,0 @@
1
- import type { PluginModuleDefinition } from './PluginModuleDefinition';
2
- export declare type SourceModuleDefinition = PluginModuleDefinition & {
3
- namespace: string;
4
- cache?: boolean;
5
- };