@wirestate/core 0.7.0-experimental.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`
@@ -10,13 +10,19 @@
10
10
  - Export more alias / methods from `@wirestate/react-mobx`
11
11
  - Export missing methods typing for `@wirestate/core`
12
12
  - Extensive JSDoc coverage for wirestate packages
13
- - `createIocContainer`: Added ability to instantly provide and activate entries, targeted seeds
13
+ - `createIocContainer`: Removed in favor of `createContainer`
14
+ - `createContainer`: Added ability to instantly provide and activate entries, targeted seeds
14
15
  - `createInjectablesProvider`: Removed.
15
16
  - `IocProvider`: Removed
16
17
  - `useRootContainer`: Added separate hook for store management in React tree
17
18
  - `ContainerProvider`: Simpler provider for containers.
18
19
  - `SubContainerProvider`: Added component solving problems of removed `createInjectablesProvider`
19
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`
20
26
 
21
27
  ## 0.6.3
22
28
 
package/README.md CHANGED
@@ -41,9 +41,9 @@ export class CounterService {
41
41
  ## Container
42
42
 
43
43
  ```ts
44
- import { createIocContainer, bindService } from "@wirestate/core";
44
+ import { createContainer, bindService } from "@wirestate/core";
45
45
 
46
- const container = createIocContainer({
46
+ const container = createContainer({
47
47
  seed: { baseUrl: "https://example.com" },
48
48
  entries: [CounterService],
49
49
  });
@@ -1718,7 +1718,7 @@ function createBaseContainer(options) {
1718
1718
  *
1719
1719
  * @example
1720
1720
  * ```typescript
1721
- * const container: Container = createIocContainer({
1721
+ * const container: Container = createContainer({
1722
1722
  * seeds: [
1723
1723
  * [CounterService, { count: 1000 }],
1724
1724
  * ["SOME_KEY", "VALUE"],
@@ -23,7 +23,7 @@ import { WirestateError } from '../error/wirestate-error.js';
23
23
  *
24
24
  * @example
25
25
  * ```typescript
26
- * const container: Container = createIocContainer({
26
+ * const container: Container = createContainer({
27
27
  * seeds: [
28
28
  * [CounterService, { count: 1000 }],
29
29
  * ["SOME_KEY", "VALUE"],
package/index.d.ts CHANGED
@@ -550,7 +550,7 @@ interface CreateContainerOptions {
550
550
  *
551
551
  * @example
552
552
  * ```typescript
553
- * const container: Container = createIocContainer({
553
+ * const container: Container = createContainer({
554
554
  * seeds: [
555
555
  * [CounterService, { count: 1000 }],
556
556
  * ["SOME_KEY", "VALUE"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wirestate/core",
3
- "version": "0.7.0-experimental.1",
3
+ "version": "0.7.0-experimental.2",
4
4
  "description": "Store management library core based on inversify",
5
5
  "sideEffects": false,
6
6
  "author": "Syrotenko Igor",