@nmtjs/contract
Advanced tools
Comparing version 0.3.1 to 0.3.2
@@ -12,8 +12,8 @@ { | ||
"peerDependencies": { | ||
"@nmtjs/type": "0.3.1", | ||
"@nmtjs/common": "0.3.1" | ||
"@nmtjs/common": "0.3.2", | ||
"@nmtjs/type": "0.3.2" | ||
}, | ||
"devDependencies": { | ||
"@nmtjs/type": "0.3.1", | ||
"@nmtjs/common": "0.3.1" | ||
"@nmtjs/common": "0.3.2", | ||
"@nmtjs/type": "0.3.2" | ||
}, | ||
@@ -27,3 +27,3 @@ "files": [ | ||
], | ||
"version": "0.3.1", | ||
"version": "0.3.2", | ||
"scripts": { | ||
@@ -30,0 +30,0 @@ "build": "neemata-build -p neutral --root=./src './**/*.ts'", |
@@ -15,3 +15,3 @@ import { | ||
string, | ||
TProcedureContract | TSubscriptionContract | ||
TBaseProcedureContract | ||
>, | ||
@@ -80,3 +80,6 @@ Events extends Record<string, TEventContract> = Record< | ||
Transports extends { [key: string]: true }, | ||
Procedures extends Record<string, TProcedureContract | TSubscriptionContract>, | ||
Procedures extends Record< | ||
string, | ||
TBaseProcedureContract | TProcedureContract | TSubscriptionContract | ||
>, | ||
Events extends Record<string, TEventContract>, | ||
@@ -97,3 +100,3 @@ >( | ||
...procedure, | ||
events: applyNames(procedure.events, { | ||
events: applyNames((procedure as TSubscriptionContract).events, { | ||
serviceName: name, | ||
@@ -120,21 +123,1 @@ subscriptionName: procedureName, | ||
} | ||
type A<T extends boolean> = { | ||
// type: 'boolean' | ||
a: T | ||
} | ||
type B<T extends number> = { | ||
// type: 'number' | ||
b: T | ||
} | ||
type T = Record<string, A<boolean> | B<number>> | ||
type TT<TTT extends T> = { | ||
[K in keyof TTT]: TTT[K] extends A<infer T> | ||
? T | ||
: TTT[K] extends B<infer T> | ||
? T | ||
: never | ||
} | ||
type TTT = TT<{ r: A<false> }> |
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
28609
434