@wirestate/lit-signals 0.6.1 → 0.7.0-experimental.2

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/CHANGELOG.md CHANGED
@@ -1,4 +1,4 @@
1
- ## 0.7.0
1
+ ## Unreleased
2
2
 
3
3
  - Add `useScope` in `@wirestate/react`
4
4
  - New lit elements modules - `@wirestate/lit` and `@wirestate/lit-signals`
@@ -8,6 +8,21 @@
8
8
  - `WireScope`: add new event/command/query subscribe-unsubscribe methods
9
9
  - Export more alias / methods from `@wirestate/core`
10
10
  - Export more alias / methods from `@wirestate/react-mobx`
11
+ - Export missing methods typing for `@wirestate/core`
12
+ - Extensive JSDoc coverage for wirestate packages
13
+ - `createIocContainer`: Removed in favor of `createContainer`
14
+ - `createContainer`: Added ability to instantly provide and activate entries, targeted seeds
15
+ - `createInjectablesProvider`: Removed.
16
+ - `IocProvider`: Removed
17
+ - `useRootContainer`: Added separate hook for store management in React tree
18
+ - `ContainerProvider`: Simpler provider for containers.
19
+ - `SubContainerProvider`: Added component solving problems of removed `createInjectablesProvider`
20
+ - `ContainerActivator`: Added separate activation component
21
+ - Replace IoC-context provision APIs with `ContainerContext`, `containerProvide`, `ContainerProvider`, and `useContainerProvision`
22
+ - Replace injectables-provider APIs with `subContainerProvide`, `SubContainerProvider`, and `useSubContainerProvider`
23
+ - Provide plain `Container` values through Lit context instead of wrapper objects
24
+ - Recreate managed child containers when the parent container context changes
25
+ - Add `useContainer` and `useScope` consumers in `@wirestate/lit`
11
26
 
12
27
  ## 0.6.3
13
28
 
@@ -70,6 +85,6 @@
70
85
  - useService -> useInjection
71
86
  - AbstractService::getService -> AbstractService::resolve
72
87
 
73
- ## 0.1.1
88
+ ## 0.1.0
74
89
 
75
90
  - Initial release
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # @wirestate/lit-signals
1
+ # @wirestate/lit-signals [[monorepo](https://github.com/Neloreck/wirestate)] [[docs](https://neloreck.github.io/wirestate/)]
2
2
 
3
3
  [![npm](https://img.shields.io/npm/v/@wirestate/lit-signals.svg?style=flat-square)](https://www.npmjs.com/package/@wirestate/lit-signals)
4
4
  [![license](https://img.shields.io/badge/license-MIT-blue.svg?style=flat)](https://github.com/Neloreck/wirestate/blob/master/LICENSE)
@@ -14,21 +14,14 @@ npm install @wirestate/lit-signals @lit-labs/signals
14
14
  ## Usage
15
15
 
16
16
  ```ts
17
- import {
18
- signal,
19
- computed,
20
- watch,
21
- Signal,
22
- State,
23
- Computed,
24
- } from '@wirestate/lit-signals';
17
+ import { signal, computed, watch, Signal, State, Computed } from "@wirestate/lit-signals";
25
18
  ```
26
19
 
27
20
  Example service:
28
21
 
29
22
  ```ts
30
- import { Injectable, Inject, WireScope } from '@wirestate/core';
31
- import { signal, computed, State, Computed } from '@wirestate/lit-signals';
23
+ import { Injectable, Inject, WireScope } from "@wirestate/core";
24
+ import { signal, computed, State, Computed } from "@wirestate/lit-signals";
32
25
 
33
26
  @Injectable()
34
27
  export class CounterService {
@@ -46,14 +39,14 @@ export class CounterService {
46
39
  Example Lit element:
47
40
 
48
41
  ```ts
49
- import { LitElement, html } from 'lit';
50
- import { customElement } from 'lit/decorators.js';
51
- import { injection } from '@wirestate/lit';
52
- import { watch, computed } from '@wirestate/lit-signals';
42
+ import { LitElement, html } from "lit";
43
+ import { customElement } from "lit/decorators.js";
44
+ import { injection } from "@wirestate/lit";
45
+ import { watch, computed } from "@wirestate/lit-signals";
53
46
 
54
- import { CounterService } from './services';
47
+ import { CounterService } from "./services";
55
48
 
56
- @customElement('my-component')
49
+ @customElement("my-component")
57
50
  class MyComponent extends LitElement {
58
51
  @injection({ injectionId: CounterService })
59
52
  private readonly counterService!: CounterService;
package/index.d.ts CHANGED
@@ -2,12 +2,12 @@ import { Signal } from 'signal-polyfill';
2
2
  export { Signal, SignalWatcher, WatchDirective, WatchDirectiveFunction, computed, signal, watch, withWatch } from '@lit-labs/signals';
3
3
 
4
4
  /**
5
- * @group signals
5
+ * @group Signals
6
6
  * @see {@link https://lit.dev/docs/data/signals/}
7
7
  */
8
8
  type State<T> = Signal.State<T>;
9
9
  /**
10
- * @group signals
10
+ * @group Signals
11
11
  * @see {@link https://lit.dev/docs/data/signals/}
12
12
  */
13
13
  type Computed<T> = Signal.Computed<T>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wirestate/lit-signals",
3
- "version": "0.6.1",
3
+ "version": "0.7.0-experimental.2",
4
4
  "description": "Signals re-exports for wirestate lit elements",
5
5
  "sideEffects": false,
6
6
  "author": "Syrotenko Igor",