inversify 7.10.0 → 7.10.1
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 +135 -63
- package/LICENSE +1 -1
- package/README.md +5 -15
- package/lib/cjs/index.d.ts +1 -1
- package/lib/cjs/index.d.ts.map +1 -1
- package/lib/cjs/index.js.map +1 -1
- package/lib/cjs/test/annotation/inject.int.spec.d.ts +2 -0
- package/lib/cjs/test/annotation/inject.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/annotation/injectable.int.spec.d.ts +2 -0
- package/lib/cjs/test/annotation/injectable.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/annotation/multi_inject.int.spec.d.ts +2 -0
- package/lib/cjs/test/annotation/multi_inject.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/annotation/named.int.spec.d.ts +2 -0
- package/lib/cjs/test/annotation/named.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/annotation/optional.int.spec.d.ts +2 -0
- package/lib/cjs/test/annotation/optional.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/annotation/post_construct.int.spec.d.ts +2 -0
- package/lib/cjs/test/annotation/post_construct.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/bugs/bugs.int.spec.d.ts +2 -0
- package/lib/cjs/test/bugs/bugs.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_1190.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_1190.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_1190.test.js +62 -0
- package/lib/cjs/test/bugs/issue_1190.test.js.map +1 -0
- package/lib/cjs/test/bugs/issue_1297.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_1297.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_1297.test.js +66 -0
- package/lib/cjs/test/bugs/issue_1297.test.js.map +1 -0
- package/lib/cjs/test/bugs/issue_1416.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_1416.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_1416.test.js +50 -0
- package/lib/cjs/test/bugs/issue_1416.test.js.map +1 -0
- package/lib/cjs/test/bugs/issue_1515.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_1515.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_1515.test.js +71 -0
- package/lib/cjs/test/bugs/issue_1515.test.js.map +1 -0
- package/lib/cjs/test/bugs/issue_1518.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_1518.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_1518.test.js +15 -0
- package/lib/cjs/test/bugs/issue_1518.test.js.map +1 -0
- package/lib/cjs/test/bugs/issue_1564.int.spec.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_1564.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_543.int.spec.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_543.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_549.int.spec.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_549.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_706.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_706.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_706.test.js +31 -0
- package/lib/cjs/test/bugs/issue_706.test.js.map +1 -0
- package/lib/cjs/test/bugs/issue_928.test.d.ts +2 -0
- package/lib/cjs/test/bugs/issue_928.test.d.ts.map +1 -0
- package/lib/cjs/test/bugs/issue_928.test.js +68 -0
- package/lib/cjs/test/bugs/issue_928.test.js.map +1 -0
- package/lib/cjs/test/container/container.int.spec.d.ts +2 -0
- package/lib/cjs/test/container/container.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/container/container_module.int.spec.d.ts +2 -0
- package/lib/cjs/test/container/container_module.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/features/named_default.int.spec.d.ts +2 -0
- package/lib/cjs/test/features/named_default.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/features/property_injection.int.spec.d.ts +2 -0
- package/lib/cjs/test/features/property_injection.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/features/provider.int.spec.d.ts +2 -0
- package/lib/cjs/test/features/provider.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/features/request_scope.int.spec.d.ts +2 -0
- package/lib/cjs/test/features/request_scope.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/features/transitive_bindings.int.spec.d.ts +2 -0
- package/lib/cjs/test/features/transitive_bindings.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/inversify.int.spec.d.ts +2 -0
- package/lib/cjs/test/inversify.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/node/error_messages.int.spec.d.ts +2 -0
- package/lib/cjs/test/node/error_messages.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/node/exceptions.int.spec.d.ts +2 -0
- package/lib/cjs/test/node/exceptions.int.spec.d.ts.map +1 -0
- package/lib/cjs/test/node/proxies.int.spec.d.ts +2 -0
- package/lib/cjs/test/node/proxies.int.spec.d.ts.map +1 -0
- package/lib/esm/index.d.ts +1 -1
- package/lib/esm/index.d.ts.map +1 -1
- package/package.json +27 -47
package/CHANGELOG.md
CHANGED
|
@@ -1,61 +1,68 @@
|
|
|
1
|
-
#
|
|
2
|
-
All notable changes to this project from 5.0.0 forward will be documented in this file.
|
|
1
|
+
# inversify
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
3
|
+
## 7.10.1
|
|
6
4
|
|
|
7
|
-
|
|
5
|
+
### Patch Changes
|
|
8
6
|
|
|
9
|
-
|
|
7
|
+
- Added `MapToResolvedValueInjectOptions` type
|
|
10
8
|
|
|
11
|
-
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
- @inversifyjs/container@1.13.1
|
|
12
11
|
|
|
13
|
-
##
|
|
12
|
+
## 7.10.0
|
|
14
13
|
|
|
15
14
|
### Added
|
|
15
|
+
|
|
16
16
|
- Added `InjectFromBaseOptionsLifecycle`.
|
|
17
17
|
- Added `InjectFromHierarchyOptionsLifecycle`.
|
|
18
18
|
|
|
19
19
|
### Changed
|
|
20
|
+
|
|
20
21
|
- Updated `injectFromBase` with `lifecycle` property.
|
|
21
22
|
- Updated `injectFromHierarchy` with `lifecycle` property.
|
|
22
23
|
|
|
23
|
-
##
|
|
24
|
+
## 7.9.1
|
|
24
25
|
|
|
25
26
|
### Changed
|
|
27
|
+
|
|
26
28
|
- Updated `Container` to trigger autobind options on autobound parent container related binding requests.
|
|
27
29
|
|
|
28
|
-
##
|
|
30
|
+
## 7.9.0
|
|
29
31
|
|
|
30
32
|
### Changed
|
|
31
33
|
|
|
32
34
|
- Updated `decorate` to allow method parameter decoration.
|
|
33
35
|
|
|
34
|
-
##
|
|
36
|
+
## 7.8.1
|
|
35
37
|
|
|
36
38
|
### Changed
|
|
39
|
+
|
|
37
40
|
- Fixed `injectFromHierarchy` avoiding crash when traversing `Object` metadata.
|
|
38
41
|
|
|
39
|
-
##
|
|
42
|
+
## 7.8.0
|
|
40
43
|
|
|
41
44
|
### Added
|
|
45
|
+
|
|
42
46
|
- Added `injectFromHierarchy`.
|
|
43
47
|
|
|
44
|
-
##
|
|
48
|
+
## 7.7.1
|
|
45
49
|
|
|
46
50
|
### Changed
|
|
51
|
+
|
|
47
52
|
- Fixed a bug involving circular dependencies when resolving services in some edge cases.
|
|
48
53
|
- Fixed a bug involving circular dependencies when bindings are bound in some edge cases.
|
|
49
54
|
|
|
50
|
-
##
|
|
55
|
+
## 7.7.1-beta.0
|
|
51
56
|
|
|
52
57
|
### Changed
|
|
58
|
+
|
|
53
59
|
- Fixed a bug causing `Container.bind` and `Container.unbind` to avoid throwing planning errors.
|
|
54
60
|
- Fixed a bug causing wrong cached plans involving bindings with ancestor related constraints.
|
|
55
61
|
|
|
56
|
-
##
|
|
62
|
+
## 7.7.0
|
|
57
63
|
|
|
58
64
|
### Added
|
|
65
|
+
|
|
59
66
|
- Added `Bind` type.
|
|
60
67
|
- Added `IsBound` type.
|
|
61
68
|
- Added `OnActivation` type.
|
|
@@ -66,133 +73,154 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
66
73
|
- Added `UnbindSync` type.
|
|
67
74
|
|
|
68
75
|
### Changed
|
|
76
|
+
|
|
69
77
|
- Updated `BindOnFluentSyntaxImplementation.onDeactivation` to throw an error on non singleton scoped bindings.
|
|
70
78
|
- Updated `ServiceResolutionManager` to provide right `getChained` operation after computed properties are reset.
|
|
71
79
|
- Updated `Container` to properly manage bindings bindings on child containers after a parent container restores a snapshot.
|
|
72
80
|
|
|
73
|
-
##
|
|
81
|
+
## 7.6.1
|
|
74
82
|
|
|
75
83
|
### Changed
|
|
84
|
+
|
|
76
85
|
- Updated `getAll` and `getAllAsync` options with missing `chained` property.
|
|
77
86
|
|
|
78
|
-
##
|
|
87
|
+
## 7.6.0
|
|
79
88
|
|
|
80
89
|
### Added
|
|
90
|
+
|
|
81
91
|
- Added `MultiInjectOptions`.
|
|
82
92
|
|
|
83
93
|
### Changed
|
|
94
|
+
|
|
84
95
|
- Updated `multiInject` decorator with optional `MultiInjectOptions`.
|
|
85
96
|
- Updated `getAll` and `getAllAsync` options with optional`chained` property.
|
|
86
97
|
|
|
87
|
-
##
|
|
98
|
+
## 7.5.4
|
|
88
99
|
|
|
89
100
|
### Changed
|
|
101
|
+
|
|
90
102
|
- Updated `ServiceIdentifier` to rely on `Function` again. This solves an issue affecting classes with protected constructors.
|
|
91
103
|
|
|
92
|
-
##
|
|
104
|
+
## 7.5.3
|
|
93
105
|
|
|
94
106
|
### Changed
|
|
107
|
+
|
|
95
108
|
- Updated `ServiceIdentifier` removing `Function` in favor of a new `AbstractNewable` type. ServiceIdentifier now uses AbstractNewable instead of Function to better represent abstract classes. This provides better type safety and semantics.
|
|
96
109
|
|
|
97
|
-
##
|
|
110
|
+
## 7.5.2
|
|
98
111
|
|
|
99
112
|
### Changed
|
|
113
|
+
|
|
100
114
|
- Fixed `Container.snapshot` so snapshot bindings are not updated after a snapshot is taken.
|
|
101
115
|
- Fixed a memory leak affecting child containers.
|
|
102
116
|
|
|
103
|
-
##
|
|
117
|
+
## 7.5.1
|
|
104
118
|
|
|
105
119
|
### Changed
|
|
120
|
+
|
|
106
121
|
- Updated `Container.get` like methods to properly set bindings when autobind mode is set:
|
|
107
122
|
- `@injectable` scopes properly handled.
|
|
108
123
|
- Autobind mode no longer creates duplicated bindings.
|
|
109
124
|
|
|
110
|
-
##
|
|
125
|
+
## 7.5.0
|
|
111
126
|
|
|
112
127
|
### Changed
|
|
128
|
+
|
|
113
129
|
- Updated `Container` with `unloadSync`.
|
|
114
130
|
- Updated `Container` with `loadSync`.
|
|
115
131
|
|
|
116
|
-
##
|
|
132
|
+
## 7.4.0
|
|
117
133
|
|
|
118
134
|
### Changed
|
|
135
|
+
|
|
119
136
|
- Updated `ContainerModuleLoadOptions` with `rebind`.
|
|
120
137
|
- Updated `ContainerModuleLoadOptions` with `rebindSync`.
|
|
121
138
|
- Updated `BindToFluentSyntax.toResolvedValue` with additional type constraints.
|
|
122
139
|
|
|
123
|
-
##
|
|
140
|
+
## 7.3.0
|
|
124
141
|
|
|
125
142
|
### Changed
|
|
143
|
+
|
|
126
144
|
- Updated `Container` with `rebindSync`.
|
|
127
145
|
- Updated `Container` with `unbindSync`.
|
|
128
146
|
- Updated `Container` with `rebind`.
|
|
129
147
|
- Updated `ContainerModuleLoadOptions` with `unbindSync`.
|
|
130
148
|
- Updated `ContainerModuleLoadOptions.unbind` to accept `BindingIdentifier`.
|
|
131
149
|
|
|
132
|
-
##
|
|
150
|
+
## 7.2.0
|
|
133
151
|
|
|
134
152
|
### Added
|
|
153
|
+
|
|
135
154
|
- Added `BindingIdentifier`.
|
|
136
155
|
|
|
137
156
|
### Changed
|
|
157
|
+
|
|
138
158
|
- Updated `BindInFluentSyntax` with `getIdentifier`.
|
|
139
159
|
- Updated `Container.unbind` to handle `BindingIdentifier`.
|
|
140
160
|
- Updated `BindOnFluentSyntax` with `getIdentifier`.
|
|
141
161
|
- Updated `BindWhenFluentSyntax` with `getIdentifier`.
|
|
142
162
|
|
|
143
|
-
##
|
|
163
|
+
## 7.1.0
|
|
144
164
|
|
|
145
165
|
### Added
|
|
166
|
+
|
|
146
167
|
- Added `BindingActivation`.
|
|
147
168
|
- Added `BindingDeactivation`.
|
|
148
169
|
|
|
149
|
-
##
|
|
170
|
+
## 7.0.2
|
|
150
171
|
|
|
151
172
|
### Changed
|
|
173
|
+
|
|
152
174
|
- Updated `container.get` like methods to no longer initialize twice singleton scoped bindings.
|
|
153
175
|
|
|
154
|
-
##
|
|
176
|
+
## 7.0.1
|
|
155
177
|
|
|
156
178
|
### Changed
|
|
179
|
+
|
|
157
180
|
- Updated `Container.get` like methods to no longer initialize twice singleton scoped bindings.
|
|
158
181
|
|
|
159
|
-
##
|
|
182
|
+
## 7.0.0
|
|
160
183
|
|
|
161
184
|
Parity version with `7.0.0-alpha.5`
|
|
162
185
|
|
|
163
|
-
##
|
|
186
|
+
## 7.0.0-alpha.5
|
|
164
187
|
|
|
165
188
|
### Changed
|
|
189
|
+
|
|
166
190
|
- Renamed `BindingMetadata` to `BindingConstraints`.
|
|
167
191
|
- Improved performance on `Container.get` like methods.
|
|
168
192
|
|
|
169
|
-
##
|
|
193
|
+
## 7.0.0-alpha.4
|
|
170
194
|
|
|
171
195
|
Parity version with `7.0.0-alpha.3`.
|
|
172
196
|
|
|
173
|
-
##
|
|
197
|
+
## 6.2.2
|
|
174
198
|
|
|
175
199
|
- Solved issue with npm registry.
|
|
176
200
|
|
|
177
|
-
##
|
|
201
|
+
## 7.0.0-alpha.3
|
|
178
202
|
|
|
179
203
|
### Changed
|
|
204
|
+
|
|
180
205
|
- Updated `BindToFluentSyntax` with `.toResolvedValue`.
|
|
181
206
|
|
|
182
|
-
##
|
|
207
|
+
## 7.0.0-alpha.2
|
|
183
208
|
|
|
184
209
|
### Changed
|
|
210
|
+
|
|
185
211
|
- Updated `Container` with a plan cache. `Container.get`, `Container.getAll`, `Container.getAllAsync` and `Container.getAsync` performance has been improved.
|
|
186
212
|
|
|
187
|
-
##
|
|
213
|
+
## 7.0.0-alpha.1
|
|
188
214
|
|
|
189
215
|
### Changed
|
|
216
|
+
|
|
190
217
|
- Updated `GetOptions` with `autobind`.
|
|
191
218
|
- Updated `ContainerOptions` with `autobind`.
|
|
192
219
|
|
|
193
|
-
##
|
|
220
|
+
## 7.0.0-alpha.0
|
|
194
221
|
|
|
195
222
|
### Added
|
|
223
|
+
|
|
196
224
|
- Added `BindInFluentSyntax`.
|
|
197
225
|
- Added `BindInWhenOnFluentSyntax`.
|
|
198
226
|
- Added `BindOnFluentSyntax`.
|
|
@@ -217,6 +245,7 @@ Parity version with `7.0.0-alpha.3`.
|
|
|
217
245
|
- Added `injectFromBase` decorator.
|
|
218
246
|
|
|
219
247
|
### Changed
|
|
248
|
+
|
|
220
249
|
- Updated `injectable` with optional `scope`.
|
|
221
250
|
- [Breaking] Updated `ContainerModule` constructor to receive a callback with `ContainerModuleLoadOptions` instead of `interfaces.ContainerModuleCallBack`.
|
|
222
251
|
- [Breaking] Updated `ContainerModule`.load to return `Promise<void>`.
|
|
@@ -234,11 +263,12 @@ Parity version with `7.0.0-alpha.3`.
|
|
|
234
263
|
- [Breaking] Updated `Container` with no `unbindAllAsync` in favor of an async `Container.unbindAll`.
|
|
235
264
|
- [Breaking] Updated `Container` with no `unloadAsync` in favor of an async `Container.unload`.
|
|
236
265
|
|
|
237
|
-
|
|
238
266
|
### Fixed
|
|
267
|
+
|
|
239
268
|
- Updated `decorate` to no longer require a unexpected prototypes to decorate property nor methods.
|
|
240
269
|
|
|
241
270
|
### Removed
|
|
271
|
+
|
|
242
272
|
- [Breaking] Removed deprecated `LazyServiceIdentifer`. Use `LazyServiceIdentifier` instead.
|
|
243
273
|
- [Breaking] Removed `BindingScopeEnum`. Use `bindingScopeValues` instead.
|
|
244
274
|
- [Breaking] Removed `BindingTypeEnum`.
|
|
@@ -256,18 +286,20 @@ Parity version with `7.0.0-alpha.3`.
|
|
|
256
286
|
- [Breaking] Removed `getServiceIdentifierAsString`.
|
|
257
287
|
- [Breaking] Removed `multiBindToService`.
|
|
258
288
|
|
|
259
|
-
|
|
260
|
-
## [6.2.1]
|
|
289
|
+
## 6.2.1
|
|
261
290
|
|
|
262
291
|
### Fixed
|
|
292
|
+
|
|
263
293
|
- Added missing `LazyServiceIdentifer`.
|
|
264
294
|
|
|
265
|
-
##
|
|
295
|
+
## 6.2.0
|
|
266
296
|
|
|
267
297
|
### Added
|
|
298
|
+
|
|
268
299
|
- Added `interfaces.GetAllOptions`.
|
|
269
300
|
|
|
270
301
|
### Changed
|
|
302
|
+
|
|
271
303
|
- Updated `container.getAll` with `options` optional param.
|
|
272
304
|
- Updated `container.getAllAsync` with `options` optional param.
|
|
273
305
|
- Updated `interfaces.NextArgs` with optional `isOptional` param.
|
|
@@ -284,11 +316,12 @@ Parity version with `7.0.0-alpha.3`.
|
|
|
284
316
|
- Updated `container` with `tryGetAllNamed`.
|
|
285
317
|
- Updated `container` with `tryGetAllNamedAsync`.
|
|
286
318
|
|
|
287
|
-
##
|
|
319
|
+
## 6.2.0-beta.1
|
|
288
320
|
|
|
289
321
|
### Added
|
|
290
322
|
|
|
291
323
|
### Changed
|
|
324
|
+
|
|
292
325
|
- Updated `interfaces.NextArgs` with optional `isOptional` param.
|
|
293
326
|
- Updated `container` with `tryGet`.
|
|
294
327
|
- Updated `container` with `tryGetAsync`.
|
|
@@ -305,126 +338,151 @@ Parity version with `7.0.0-alpha.3`.
|
|
|
305
338
|
|
|
306
339
|
### Fixed
|
|
307
340
|
|
|
308
|
-
##
|
|
341
|
+
## 6.2.0-beta.0
|
|
309
342
|
|
|
310
343
|
### Added
|
|
344
|
+
|
|
311
345
|
- Added `interfaces.GetAllOptions`.
|
|
312
346
|
|
|
313
347
|
### Changed
|
|
348
|
+
|
|
314
349
|
- Updated `container.getAll` with `options` optional param.
|
|
315
350
|
- Updated `container.getAllAsync` with `options` optional param.
|
|
316
351
|
|
|
317
352
|
### Fixed
|
|
318
353
|
|
|
319
|
-
##
|
|
354
|
+
## 6.1.6
|
|
320
355
|
|
|
321
356
|
### Fixed
|
|
357
|
+
|
|
322
358
|
- Fixed unexpected property access while running planning checks on injected base types.
|
|
323
359
|
- Updated ESM sourcemaps to refelct the right source code files.
|
|
324
360
|
|
|
325
|
-
##
|
|
361
|
+
## 6.1.5
|
|
326
362
|
|
|
327
363
|
### Changed
|
|
364
|
+
|
|
328
365
|
- Updated library to import `reflect-metadata`. Importing `reflect-metadata` before bootstraping a module in the userland is no longer required.
|
|
329
366
|
|
|
330
367
|
### Fixed
|
|
368
|
+
|
|
331
369
|
- Updated ESM build to provide proper types regardless of the ts resolution module strategy in the userland.
|
|
332
370
|
- Fixed container to properly resolve async `.toService` bindings.
|
|
333
371
|
- Fixed `.toService` binding to properly disable caching any values.
|
|
334
372
|
|
|
335
|
-
##
|
|
373
|
+
## 6.1.5-beta.2
|
|
336
374
|
|
|
337
375
|
### Fixed
|
|
376
|
+
|
|
338
377
|
- Updated ESM bundled types to solve circularly referenced types.
|
|
339
378
|
|
|
340
|
-
##
|
|
379
|
+
## 6.1.5-beta.1
|
|
341
380
|
|
|
342
381
|
### Fixed
|
|
382
|
+
|
|
343
383
|
- Updated ESM build to provide proper types regardless of the ts resolution module strategy in the userland.
|
|
344
384
|
|
|
345
|
-
##
|
|
385
|
+
## 6.1.5-beta.0
|
|
346
386
|
|
|
347
387
|
### Changed
|
|
388
|
+
|
|
348
389
|
- Updated library to import `reflect-metadata`. Importing `reflect-metadata` before bootstraping a module in the userland is no longer required.
|
|
349
390
|
|
|
350
391
|
### Fixed
|
|
392
|
+
|
|
351
393
|
- Fixed container to properly resolve async `.toService` bindings.
|
|
352
394
|
- Fixed `.toService` binding to properly disable caching any values.
|
|
353
395
|
|
|
354
|
-
##
|
|
396
|
+
## 6.1.4
|
|
355
397
|
|
|
356
398
|
### Changed
|
|
399
|
+
|
|
357
400
|
- Updated planner with better error description when a binding can not be properly resolved.
|
|
358
401
|
|
|
359
402
|
### Fixed
|
|
403
|
+
|
|
360
404
|
- Updated container to allow deactivating singleton undefined values.
|
|
361
405
|
- Updated ESM build to be compatible with both bundler and NodeJS module resolution algorithms.
|
|
362
406
|
|
|
363
|
-
##
|
|
407
|
+
## 6.1.4-beta.1
|
|
364
408
|
|
|
365
409
|
### Fixed
|
|
410
|
+
|
|
366
411
|
- Updated ESM build to be compatible with both bundler and NodeJS module resolution algorithms.
|
|
367
412
|
|
|
368
|
-
##
|
|
413
|
+
## 6.1.4-beta.0
|
|
369
414
|
|
|
370
415
|
### Changed
|
|
416
|
+
|
|
371
417
|
- Updated planner with better error description when a binding can not be properly resolved.
|
|
372
418
|
|
|
373
|
-
##
|
|
419
|
+
## 6.1.3
|
|
374
420
|
|
|
375
421
|
### Fixed
|
|
422
|
+
|
|
376
423
|
- Updated ESM build with missing types.
|
|
377
424
|
|
|
378
|
-
##
|
|
425
|
+
## 6.1.2
|
|
379
426
|
|
|
380
427
|
### Changed
|
|
428
|
+
|
|
381
429
|
- Updated `package.json` to include the `exports` field for better bundler support.
|
|
382
430
|
|
|
383
431
|
### Fixed
|
|
432
|
+
|
|
384
433
|
- Updated fetch metadata flows with better error descriptions.
|
|
385
434
|
|
|
386
|
-
##
|
|
435
|
+
## 6.1.2-beta.1
|
|
387
436
|
|
|
388
437
|
### Changed
|
|
438
|
+
|
|
389
439
|
- Updated `package.json` to include the `exports` field for better bundler support.
|
|
390
440
|
|
|
391
|
-
##
|
|
441
|
+
## 6.1.2-beta.0
|
|
392
442
|
|
|
393
443
|
### Fixed
|
|
444
|
+
|
|
394
445
|
- Updated fetch metadata flows with better error descriptions.
|
|
395
446
|
|
|
396
|
-
##
|
|
447
|
+
## 6.1.1
|
|
397
448
|
|
|
398
449
|
### Fixed
|
|
450
|
+
|
|
399
451
|
- Bumped `@inversifyjs/common` and `@inversifyjs/core` fixing wrong dev engines constraints.
|
|
400
452
|
|
|
401
|
-
##
|
|
453
|
+
## 6.1.0
|
|
402
454
|
|
|
403
455
|
### Changed
|
|
456
|
+
|
|
404
457
|
- Updated `ServiceIdentifier` to rely on `Function` instead of `Abstract<T>`.
|
|
405
458
|
|
|
406
459
|
### Fixed
|
|
460
|
+
|
|
407
461
|
- Fixed `Target.getNameTag` with the right type: `number | string | symbol`.
|
|
408
462
|
- Fixed `interfaces.ModuleActivationStore.addDeactivation` to enforce `serviceIdentifier` and `onDeactivation` are consistent.
|
|
409
463
|
- Fixed `interfaces.ModuleActivationStore.addActivation` to enforce `serviceIdentifier` and `onDeactivation` are consistent.
|
|
410
464
|
|
|
411
|
-
##
|
|
465
|
+
## 6.0.3
|
|
412
466
|
|
|
413
467
|
### Fixed
|
|
468
|
+
|
|
414
469
|
property injection tagged as @optional no longer overrides default values with `undefined`.
|
|
415
470
|
Updated `targetName` to be a valid `typescript@5` decorator.
|
|
416
471
|
|
|
417
|
-
##
|
|
472
|
+
## 6.0.2
|
|
418
473
|
|
|
419
474
|
### Added
|
|
475
|
+
|
|
420
476
|
Brought tests up to 100% Code Coverage
|
|
421
477
|
|
|
422
478
|
### Changed
|
|
479
|
+
|
|
423
480
|
LazyIdentfier Tests
|
|
424
481
|
Removed browser test pipeline, browserify, karma (#1542)
|
|
425
482
|
Update all dependencies except typescript (#1531)
|
|
426
483
|
|
|
427
484
|
### Fixed
|
|
485
|
+
|
|
428
486
|
Less than 100% code coverage
|
|
429
487
|
Use default class property for @optional injected properties (#1467)
|
|
430
488
|
Remove circular import (#1516)
|
|
@@ -432,8 +490,10 @@ Fix strict type checking on @unmanaged decorator (#1499)
|
|
|
432
490
|
Fix typo (LazyServiceIdentifer -> LazyServiceIdentifier) (#1483)
|
|
433
491
|
Fix typo (circular dependency error message) (#1485)
|
|
434
492
|
|
|
435
|
-
##
|
|
493
|
+
## 6.0.1 - 2021-10-14
|
|
494
|
+
|
|
436
495
|
### Added
|
|
496
|
+
|
|
437
497
|
- add API method for check dependency only in current container
|
|
438
498
|
- createTaggedDecorator #1343
|
|
439
499
|
- Async bindings #1132
|
|
@@ -444,39 +504,51 @@ Fix typo (circular dependency error message) (#1485)
|
|
|
444
504
|
- Added @preDestroy decorator #1132
|
|
445
505
|
|
|
446
506
|
### Changed
|
|
507
|
+
|
|
447
508
|
- @postConstruct can target an asyncronous function #1132
|
|
448
509
|
- Singleton scoped services cache resolved values once the result promise is fulfilled #1320
|
|
449
510
|
|
|
450
511
|
### Fixed
|
|
512
|
+
|
|
451
513
|
- only inject decorator can be applied to setters #1342
|
|
452
514
|
- Container.resolve should resolve in that container #1338
|
|
453
515
|
|
|
454
|
-
##
|
|
516
|
+
## 5.1.1 - 2021-04-25
|
|
517
|
+
|
|
455
518
|
-Fix pre-publish for build artifacts
|
|
456
519
|
|
|
457
|
-
##
|
|
520
|
+
## 5.1.0 - 2021-04-25
|
|
521
|
+
|
|
458
522
|
### Added
|
|
523
|
+
|
|
459
524
|
- Upgrade information for v4.x to v5.x
|
|
460
525
|
|
|
461
526
|
### Changed
|
|
527
|
+
|
|
462
528
|
- Update BindingToSyntax with `.toAutoNamedFactory()`.
|
|
463
529
|
|
|
464
530
|
### Fixed
|
|
531
|
+
|
|
465
532
|
- Fix `Target.isTagged()` to exclude `optional` from tag injections #1190.
|
|
466
533
|
- Update `toConstructor`, `toFactory`, `toFunction`, `toAutoFactory`, `toProvider` and `toConstantValue` to have singleton scope #1297.
|
|
467
534
|
- Fix injection on optional properties when targeting ES6 #928
|
|
468
535
|
|
|
469
|
-
##
|
|
536
|
+
## 5.0.1 - 2018-10-17
|
|
537
|
+
|
|
470
538
|
### Added
|
|
539
|
+
|
|
471
540
|
- Updating constructor injection wiki document with concrete injection example #922
|
|
472
541
|
|
|
473
542
|
### Changed
|
|
543
|
+
|
|
474
544
|
- Change GUID to incremented counter for better performance #882
|
|
475
545
|
|
|
476
546
|
### Fixed
|
|
547
|
+
|
|
477
548
|
- fix broken compilation by adding `.toString()` so symbols serialization #893
|
|
478
549
|
- Fix problem with applying options on Container.resolve (fix #914) #915
|
|
479
550
|
- Fixed documentation issues
|
|
480
551
|
|
|
481
|
-
##
|
|
552
|
+
## 4.14.0 - 2018-10-16
|
|
553
|
+
|
|
482
554
|
Deprecated - Replaced by 5.0.1
|
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
> [!NOTE]
|
|
2
|
+
> InversifyJS will be moving to the [monorepo](https://github.com/inversify/monorepo). Please, consider creating issues and pull requests there.
|
|
3
|
+
>
|
|
4
|
+
> Next releases will be published in the monorepo, so consider starring it to be notified.
|
|
5
|
+
|
|
1
6
|
<p align="center">
|
|
2
7
|
<a href="https://www.npmjs.com/package/inversify" target="__blank"><img src="https://img.shields.io/npm/v/inversify?color=0476bc&label=" alt="NPM version"></a>
|
|
3
8
|
<a href="https://www.npmjs.com/package/inversify" target="__blank"><img alt="NPM Downloads" src="https://img.shields.io/npm/dm/inversify?color=3890aa&label="></a>
|
|
@@ -6,7 +11,6 @@
|
|
|
6
11
|
<br>
|
|
7
12
|
<br>
|
|
8
13
|
<a href="https://github.com/inversify/InversifyJS" target="__blank"><img alt="GitHub stars" src="https://img.shields.io/github/stars/inversify/InversifyJS?style=social"></a>
|
|
9
|
-
<!--<a href="https://twitter.com/inversifyjs" target="__blank"><img alt="Twitter" src="https://img.shields.io/twitter/follow/InversifyJS.svg?maxAge=86400&style=social"></a>-->
|
|
10
14
|
<a href="https://discord.gg/jXcMagAPnm" target="__blank"><img alt="Discord Server" src="https://img.shields.io/discord/816766547879657532?style=social&logo=discord"></a>
|
|
11
15
|
</p>
|
|
12
16
|
|
|
@@ -57,17 +61,3 @@ InversifyJS has been developed with 4 main goals:
|
|
|
57
61
|
## Acknowledgements
|
|
58
62
|
|
|
59
63
|
Thanks a lot to all the [contributors](https://github.com/inversify/InversifyJS/graphs/contributors), all the developers out there using InversifyJS and all those that help us to spread the word by sharing content about InversifyJS online. Without your feedback and support this project would not be possible.
|
|
60
|
-
|
|
61
|
-
## License
|
|
62
|
-
|
|
63
|
-
License under the MIT License (MIT)
|
|
64
|
-
|
|
65
|
-
Copyright © 2015-2017 [Remo H. Jansen](http://www.remojansen.com)
|
|
66
|
-
|
|
67
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
68
|
-
|
|
69
|
-
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
70
|
-
|
|
71
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
72
|
-
|
|
73
|
-
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/lib/cjs/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import 'reflect-metadata';
|
|
2
2
|
export { Newable, LazyServiceIdentifier, ServiceIdentifier, } from '@inversifyjs/common';
|
|
3
|
-
export { Bind, BindInFluentSyntax, BindingIdentifier, BindInWhenOnFluentSyntax, BindOnFluentSyntax, BindToFluentSyntax, BindWhenFluentSyntax, BindWhenOnFluentSyntax, BoundServiceSyntax, Container, ContainerModule, ContainerModuleLoadOptions, ContainerOptions, IsBound, IsBoundOptions, OnActivation, OnDeactivation, Rebind, RebindSync, ResolvedValueInjectOptions, ResolvedValueMetadataInjectOptions, ResolvedValueMetadataInjectTagOptions, Unbind, UnbindSync, } from '@inversifyjs/container';
|
|
3
|
+
export { Bind, BindInFluentSyntax, BindingIdentifier, BindInWhenOnFluentSyntax, BindOnFluentSyntax, BindToFluentSyntax, BindWhenFluentSyntax, BindWhenOnFluentSyntax, BoundServiceSyntax, Container, ContainerModule, ContainerModuleLoadOptions, ContainerOptions, IsBound, IsBoundOptions, MapToResolvedValueInjectOptions, OnActivation, OnDeactivation, Rebind, RebindSync, ResolvedValueInjectOptions, ResolvedValueMetadataInjectOptions, ResolvedValueMetadataInjectTagOptions, Unbind, UnbindSync, } from '@inversifyjs/container';
|
|
4
4
|
export { BindingActivation, BindingConstraints, BindingDeactivation, BindingScope, DynamicValueBuilder, Factory, GetAllOptions, GetOptions, GetOptionsTagConstraint, InjectFromBaseOptions, InjectFromBaseOptionsLifecycle, InjectFromHierarchyOptions, InjectFromHierarchyOptionsLifecycle, MetadataName, MetadataTag, MultiInjectOptions, OptionalGetOptions, Provider, ResolutionContext, bindingScopeValues, bindingTypeValues, decorate, inject, injectFromBase, injectFromHierarchy, injectable, multiInject, named, optional, unmanaged, tagged, postConstruct, preDestroy, } from '@inversifyjs/core';
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
package/lib/cjs/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAE1B,OAAO,EACL,OAAO,EACP,qBAAqB,EACrB,iBAAiB,GAClB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,IAAI,EACJ,kBAAkB,EAClB,iBAAiB,EACjB,wBAAwB,EACxB,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,SAAS,EACT,eAAe,EACf,0BAA0B,EAC1B,gBAAgB,EAChB,OAAO,EACP,cAAc,EACd,YAAY,EACZ,cAAc,EACd,MAAM,EACN,UAAU,EACV,0BAA0B,EAC1B,kCAAkC,EAClC,qCAAqC,EACrC,MAAM,EACN,UAAU,GACX,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,YAAY,EACZ,mBAAmB,EACnB,OAAO,EACP,aAAa,EACb,UAAU,EACV,uBAAuB,EACvB,qBAAqB,EACrB,8BAA8B,EAC9B,0BAA0B,EAC1B,mCAAmC,EACnC,YAAY,EACZ,WAAW,EACX,kBAAkB,EAClB,kBAAkB,EAElB,QAAQ,EACR,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,EACjB,QAAQ,EACR,MAAM,EACN,cAAc,EACd,mBAAmB,EACnB,UAAU,EACV,WAAW,EACX,KAAK,EACL,QAAQ,EACR,SAAS,EACT,MAAM,EACN,aAAa,EACb,UAAU,GACX,MAAM,mBAAmB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAE1B,OAAO,EACL,OAAO,EACP,qBAAqB,EACrB,iBAAiB,GAClB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,IAAI,EACJ,kBAAkB,EAClB,iBAAiB,EACjB,wBAAwB,EACxB,kBAAkB,EAClB,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,SAAS,EACT,eAAe,EACf,0BAA0B,EAC1B,gBAAgB,EAChB,OAAO,EACP,cAAc,EACd,+BAA+B,EAC/B,YAAY,EACZ,cAAc,EACd,MAAM,EACN,UAAU,EACV,0BAA0B,EAC1B,kCAAkC,EAClC,qCAAqC,EACrC,MAAM,EACN,UAAU,GACX,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,YAAY,EACZ,mBAAmB,EACnB,OAAO,EACP,aAAa,EACb,UAAU,EACV,uBAAuB,EACvB,qBAAqB,EACrB,8BAA8B,EAC9B,0BAA0B,EAC1B,mCAAmC,EACnC,YAAY,EACZ,WAAW,EACX,kBAAkB,EAClB,kBAAkB,EAElB,QAAQ,EACR,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,EACjB,QAAQ,EACR,MAAM,EACN,cAAc,EACd,mBAAmB,EACnB,UAAU,EACV,WAAW,EACX,KAAK,EACL,QAAQ,EACR,SAAS,EACT,MAAM,EACN,aAAa,EACb,UAAU,GACX,MAAM,mBAAmB,CAAC"}
|
package/lib/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;AAAA,4BAA0B;AAE1B,8CAI6B;AAF3B,+GAAA,qBAAqB,OAAA;AAGvB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;AAAA,4BAA0B;AAE1B,8CAI6B;AAF3B,+GAAA,qBAAqB,OAAA;AAGvB,oDA0BgC;AAhB9B,sGAAA,SAAS,OAAA;AACT,4GAAA,eAAe,OAAA;AAgBjB,0CAmC2B;AAdzB,0GAAA,kBAAkB,OAAA;AAClB,yGAAA,iBAAiB,OAAA;AACjB,gGAAA,QAAQ,OAAA;AACR,8FAAA,MAAM,OAAA;AACN,sGAAA,cAAc,OAAA;AACd,2GAAA,mBAAmB,OAAA;AACnB,kGAAA,UAAU,OAAA;AACV,mGAAA,WAAW,OAAA;AACX,6FAAA,KAAK,OAAA;AACL,gGAAA,QAAQ,OAAA;AACR,iGAAA,SAAS,OAAA;AACT,8FAAA,MAAM,OAAA;AACN,qGAAA,aAAa,OAAA;AACb,kGAAA,UAAU,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inject.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/annotation/inject.int.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"injectable.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/annotation/injectable.int.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"multi_inject.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/annotation/multi_inject.int.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"named.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/annotation/named.int.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"optional.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/annotation/optional.int.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"post_construct.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/annotation/post_construct.int.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bugs.int.spec.d.ts","sourceRoot":"","sources":["../../../../src/test/bugs/bugs.int.spec.ts"],"names":[],"mappings":""}
|