@compass-framework/plugin 1.3.3 → 1.3.4
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/.eslintrc.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
const path = require('path');
|
|
2
|
+
const baseConfig = require("../../.eslintrc.js")
|
|
3
|
+
|
|
4
|
+
module.exports = {
|
|
5
|
+
...baseConfig,
|
|
6
|
+
"parserOptions": {
|
|
7
|
+
"warnOnUnsupportedTypeScriptVersion": false,
|
|
8
|
+
"ecmaVersion": 12,
|
|
9
|
+
"sourceType": "module",
|
|
10
|
+
"project": path.resolve(__dirname, "tsconfig.json")
|
|
11
|
+
}
|
|
12
|
+
}
|
package/@types/BasePlugin.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {PluginIdentifier} from "./PluginIdentifier";
|
|
1
|
+
import { Environment } from "./PluginRuntime";
|
|
2
|
+
import { PluginIdentifier } from "./PluginIdentifier";
|
|
3
3
|
|
|
4
4
|
export declare abstract class BasePlugin<Arguments = {}> {
|
|
5
5
|
public abstract onCreated(args: Arguments): Promise<PluginIdentifier>;
|
|
6
6
|
|
|
7
|
-
public abstract onMounted(
|
|
7
|
+
public abstract onMounted(env: Environment): Promise<void>;
|
|
8
8
|
|
|
9
9
|
public abstract onRemoved(): void;
|
|
10
10
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {BasePlugin} from "./BasePlugin";
|
|
2
|
-
import {
|
|
1
|
+
import { BasePlugin } from "./BasePlugin";
|
|
2
|
+
import { Environment } from "./PluginRuntime";
|
|
3
3
|
|
|
4
4
|
export declare abstract class BasePluginManager<Arguments = {}> {
|
|
5
5
|
protected constructor();
|
|
@@ -10,5 +10,5 @@ export declare abstract class BasePluginManager<Arguments = {}> {
|
|
|
10
10
|
|
|
11
11
|
public unInstallPlugin(plugin: BasePlugin<Arguments>): void;
|
|
12
12
|
|
|
13
|
-
public
|
|
13
|
+
public getEnvironment(): Environment;
|
|
14
14
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {PluginIdentifier} from "./PluginIdentifier";
|
|
2
|
-
import {PluginPlatform} from "./PluginPlatform";
|
|
1
|
+
import { PluginIdentifier } from "./PluginIdentifier";
|
|
2
|
+
import { PluginPlatform } from "./PluginPlatform";
|
|
3
3
|
|
|
4
|
-
export interface
|
|
4
|
+
export interface Environment {
|
|
5
5
|
exportAPIs<T>(key: PluginIdentifier<T>, apis: T): void;
|
|
6
6
|
|
|
7
7
|
importAPIs<T>(key: PluginIdentifier<T>): T;
|
package/package.json
CHANGED