reactive-di
Advanced tools
Comparing version 4.0.10 to 4.0.11
@@ -5,2 +5,7 @@ # Change Log | ||
<a name="4.0.11"></a> | ||
## [4.0.11](https://github.com/zerkalica/reactive-di/compare/v4.0.10...v4.0.11) (2017-09-10) | ||
<a name="4.0.10"></a> | ||
@@ -7,0 +12,0 @@ ## [4.0.10](https://github.com/zerkalica/reactive-di/compare/v4.0.9...v4.0.10) (2017-09-06) |
@@ -209,3 +209,3 @@ import { defaultContext, detached, memkey } from 'lom_atom'; | ||
Injector.prototype._fastNew = function _fastNew(key) { | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])); | ||
@@ -240,3 +240,3 @@ switch (a.length) { | ||
Injector.prototype.invoke = function invoke(key) { | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])); | ||
@@ -275,7 +275,9 @@ switch (a.length) { | ||
Injector.prototype.invokeWithProps = function invokeWithProps(key, props, propsChanged) { | ||
if (key.deps === undefined) { | ||
var deps = key.deps || (key._r === undefined ? undefined : key._r[1]); | ||
if (deps === undefined) { | ||
return key(props); | ||
} | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(deps); | ||
@@ -282,0 +284,0 @@ if (propsChanged === true) { |
@@ -213,3 +213,3 @@ 'use strict'; | ||
Injector.prototype._fastNew = function _fastNew(key) { | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])); | ||
@@ -244,3 +244,3 @@ switch (a.length) { | ||
Injector.prototype.invoke = function invoke(key) { | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])); | ||
@@ -279,7 +279,9 @@ switch (a.length) { | ||
Injector.prototype.invokeWithProps = function invokeWithProps(key, props, propsChanged) { | ||
if (key.deps === undefined) { | ||
var deps = key.deps || (key._r === undefined ? undefined : key._r[1]); | ||
if (deps === undefined) { | ||
return key(props); | ||
} | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(deps); | ||
@@ -286,0 +288,0 @@ if (propsChanged === true) { |
@@ -213,3 +213,3 @@ (function (global, factory) { | ||
Injector.prototype._fastNew = function _fastNew(key) { | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])); | ||
@@ -244,3 +244,3 @@ switch (a.length) { | ||
Injector.prototype.invoke = function invoke(key) { | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])); | ||
@@ -279,7 +279,9 @@ switch (a.length) { | ||
Injector.prototype.invokeWithProps = function invokeWithProps(key, props, propsChanged) { | ||
if (key.deps === undefined) { | ||
var deps = key.deps || (key._r === undefined ? undefined : key._r[1]); | ||
if (deps === undefined) { | ||
return key(props); | ||
} | ||
var a = this.resolve(key.deps); | ||
var a = this.resolve(deps); | ||
@@ -286,0 +288,0 @@ if (propsChanged === true) { |
{ | ||
"name": "reactive-di", | ||
"version": "4.0.10", | ||
"version": "4.0.11", | ||
"description": "Reactive dependency injection", | ||
@@ -16,3 +16,3 @@ "publishConfig": { | ||
"scripts": { | ||
"major": "npm run release -- --release-as major && npm run postversion", | ||
"major": "npm test && npm run build && standard-version --release-as major && npm run postversion", | ||
"release": "npm test && npm run build && standard-version && npm run postversion", | ||
@@ -19,0 +19,0 @@ "postversion": "git push --follow-tags origin master && npm publish", |
@@ -167,3 +167,3 @@ // @flow | ||
_fastNew<V>(key: any): V { | ||
const a = this.resolve(key.deps) | ||
const a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])) | ||
switch (a.length) { | ||
@@ -182,3 +182,3 @@ case 0: return new key() | ||
invoke<V>(key: Function): V { | ||
const a = this.resolve(key.deps) | ||
const a = this.resolve(key.deps || (key._r === undefined ? undefined : key._r[1])) | ||
switch (a.length) { | ||
@@ -204,6 +204,7 @@ case 0: return key() | ||
invokeWithProps<V>(key: Function, props?: Object, propsChanged?: boolean): V { | ||
if (key.deps === undefined) { | ||
const deps = key.deps || (key._r === undefined ? undefined : key._r[1]) | ||
if (deps === undefined) { | ||
return key(props) | ||
} | ||
const a = this.resolve(key.deps) | ||
const a = this.resolve(deps) | ||
if (propsChanged === true) { | ||
@@ -210,0 +211,0 @@ const listeners = this._listeners |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
180216
1994