@rws-framework/client 2.9.8 → 2.9.11

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/README.md CHANGED
@@ -368,6 +368,8 @@ export default (partedMode: boolean = false) => {
368
368
  };
369
369
  ```
370
370
 
371
+ ## RWS Decorators
372
+
371
373
  **Component needs to extend RWSViewComponent and use @RWSView decorator**:
372
374
 
373
375
  ```typescript
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@rws-framework/client",
3
3
  "private": false,
4
- "version": "2.9.8",
4
+ "version": "2.9.11",
5
5
  "main": "src/index.ts",
6
6
  "scripts": {
7
7
  "docs": "typedoc --tsconfig ./tsconfig.json"
@@ -1,4 +1,4 @@
1
- import { IRWSConfig, IRWSUser } from "../index";
1
+ import { IRWSConfig, IRWSUser, IStaticRWSPlugin } from "../index";
2
2
  import { RWSClientInstance } from "../client";
3
3
 
4
4
  import { RWSPlugin, DefaultRWSPluginOptionsType } from "../plugins/_plugin";
@@ -73,9 +73,9 @@ function get(this: RWSClientInstance, key: string): any | null
73
73
  }
74
74
 
75
75
  type PluginConstructor<T extends DefaultRWSPluginOptionsType> = new (options: T) => RWSPlugin<T>;
76
- type RWSPluginEntry<T extends DefaultRWSPluginOptionsType> = PluginConstructor<T> | [PluginConstructor<T>, T];
76
+ type RWSPluginEntry = IStaticRWSPlugin;
77
77
 
78
- function addPlugin<T extends DefaultRWSPluginOptionsType>(this: RWSClientInstance, pluginEntry: RWSPluginEntry<T>){
78
+ function addPlugin<T extends DefaultRWSPluginOptionsType>(this: RWSClientInstance, pluginEntry: RWSPluginEntry){
79
79
  const rwsWindow: RWSWindow = loadRWSRichWindow();
80
80
  const pluginClass: PluginConstructor<T> = (Array.isArray(pluginEntry) ? pluginEntry[0] : pluginEntry) as PluginConstructor<T>;
81
81
  const pluginOptions: T = (Array.isArray(pluginEntry) ? pluginEntry[1] : { enabled: true }) as T;