@wix/data-backend-public-sdk-poc
Advanced tools
Comparing version 1.0.78 to 1.0.79
@@ -28,1 +28,2 @@ "use strict"; | ||
exports.data = __importStar(require("@wix/data-backend-public-sdk-poc_data/context")); | ||
//# sourceMappingURL=context.js.map |
@@ -29,1 +29,2 @@ "use strict"; | ||
exports.data = data; | ||
//# sourceMappingURL=index.js.map |
@@ -28,1 +28,2 @@ "use strict"; | ||
exports.data = __importStar(require("@wix/data-backend-public-sdk-poc_data/meta")); | ||
//# sourceMappingURL=meta.js.map |
export * as data from '@wix/data-backend-public-sdk-poc_data/context'; | ||
//# sourceMappingURL=context.js.map |
import * as data from '@wix/data-backend-public-sdk-poc_data'; | ||
export { data }; | ||
//# sourceMappingURL=index.js.map |
export * as data from '@wix/data-backend-public-sdk-poc_data/meta'; | ||
//# sourceMappingURL=meta.js.map |
{ | ||
"name": "@wix/data-backend-public-sdk-poc", | ||
"version": "1.0.78", | ||
"version": "1.0.79", | ||
"publishConfig": { | ||
@@ -24,3 +24,3 @@ "registry": "https://registry.npmjs.org/", | ||
"dependencies": { | ||
"@wix/data-backend-public-sdk-poc_data": "1.0.30" | ||
"@wix/data-backend-public-sdk-poc_data": "1.0.31" | ||
}, | ||
@@ -50,3 +50,3 @@ "devDependencies": { | ||
}, | ||
"falconPackageHash": "d72a64ca3078db1a014ed53403e656cc299705ea6fe7d115ec847ebe" | ||
"falconPackageHash": "d1c5f35251b72541933260e522df16881d7f396e23af570b647b6108" | ||
} |
@@ -16,2 +16,6 @@ type HostModule<T, H extends Host> = { | ||
/** | ||
* Optional name of the environment, use for logging | ||
*/ | ||
name?: string; | ||
/** | ||
* Optional bast url to use for API requests, for example `www.wixapis.com` | ||
@@ -276,2 +280,68 @@ */ | ||
/** | ||
Returns a boolean for whether the given type is `never`. | ||
@link https://github.com/microsoft/TypeScript/issues/31751#issuecomment-498526919 | ||
@link https://stackoverflow.com/a/53984913/10292952 | ||
@link https://www.zhenghao.io/posts/ts-never | ||
Useful in type utilities, such as checking if something does not occur. | ||
@example | ||
``` | ||
import type {IsNever, And} from 'type-fest'; | ||
// https://github.com/andnp/SimplyTyped/blob/master/src/types/strings.ts | ||
type AreStringsEqual<A extends string, B extends string> = | ||
And< | ||
IsNever<Exclude<A, B>> extends true ? true : false, | ||
IsNever<Exclude<B, A>> extends true ? true : false | ||
>; | ||
type EndIfEqual<I extends string, O extends string> = | ||
AreStringsEqual<I, O> extends true | ||
? never | ||
: void; | ||
function endIfEqual<I extends string, O extends string>(input: I, output: O): EndIfEqual<I, O> { | ||
if (input === output) { | ||
process.exit(0); | ||
} | ||
} | ||
endIfEqual('abc', 'abc'); | ||
//=> never | ||
endIfEqual('abc', '123'); | ||
//=> void | ||
``` | ||
@category Type Guard | ||
@category Utilities | ||
*/ | ||
type IsNever<T> = [T] extends [never] ? true : false; | ||
/** | ||
An if-else-like type that resolves depending on whether the given type is `never`. | ||
@see {@link IsNever} | ||
@example | ||
``` | ||
import type {IfNever} from 'type-fest'; | ||
type ShouldBeTrue = IfNever<never>; | ||
//=> true | ||
type ShouldBeBar = IfNever<'not never', 'foo', 'bar'>; | ||
//=> 'bar' | ||
``` | ||
@category Type Guard | ||
@category Utilities | ||
*/ | ||
type IfNever<T, TypeIfNever = true, TypeIfNotNever = false> = ( | ||
IsNever<T> extends true ? TypeIfNever : TypeIfNotNever | ||
); | ||
/** | ||
Extract the keys from a type where the value type of the key extends the given `Condition`. | ||
@@ -308,17 +378,15 @@ | ||
*/ | ||
type ConditionalKeys<Base, Condition> = NonNullable< | ||
// Wrap in `NonNullable` to strip away the `undefined` type from the produced union. | ||
type ConditionalKeys<Base, Condition> = | ||
{ | ||
// Map through all the keys of the given base type. | ||
[Key in keyof Base]: | ||
[Key in keyof Base]-?: | ||
// Pick only keys with types extending the given `Condition` type. | ||
Base[Key] extends Condition | ||
// Retain this key since the condition passes. | ||
? Key | ||
// Retain this key | ||
// If the value for the key extends never, only include it if `Condition` also extends never | ||
? IfNever<Base[Key], IfNever<Condition, Key, never>, Key> | ||
// Discard this key since the condition fails. | ||
: never; | ||
// Convert the produced object into a union type of the keys which passed the conditional test. | ||
}[keyof Base] | ||
>; | ||
}[keyof Base]; | ||
@@ -325,0 +393,0 @@ /** |
@@ -16,2 +16,6 @@ type HostModule<T, H extends Host> = { | ||
/** | ||
* Optional name of the environment, use for logging | ||
*/ | ||
name?: string; | ||
/** | ||
* Optional bast url to use for API requests, for example `www.wixapis.com` | ||
@@ -276,2 +280,68 @@ */ | ||
/** | ||
Returns a boolean for whether the given type is `never`. | ||
@link https://github.com/microsoft/TypeScript/issues/31751#issuecomment-498526919 | ||
@link https://stackoverflow.com/a/53984913/10292952 | ||
@link https://www.zhenghao.io/posts/ts-never | ||
Useful in type utilities, such as checking if something does not occur. | ||
@example | ||
``` | ||
import type {IsNever, And} from 'type-fest'; | ||
// https://github.com/andnp/SimplyTyped/blob/master/src/types/strings.ts | ||
type AreStringsEqual<A extends string, B extends string> = | ||
And< | ||
IsNever<Exclude<A, B>> extends true ? true : false, | ||
IsNever<Exclude<B, A>> extends true ? true : false | ||
>; | ||
type EndIfEqual<I extends string, O extends string> = | ||
AreStringsEqual<I, O> extends true | ||
? never | ||
: void; | ||
function endIfEqual<I extends string, O extends string>(input: I, output: O): EndIfEqual<I, O> { | ||
if (input === output) { | ||
process.exit(0); | ||
} | ||
} | ||
endIfEqual('abc', 'abc'); | ||
//=> never | ||
endIfEqual('abc', '123'); | ||
//=> void | ||
``` | ||
@category Type Guard | ||
@category Utilities | ||
*/ | ||
type IsNever<T> = [T] extends [never] ? true : false; | ||
/** | ||
An if-else-like type that resolves depending on whether the given type is `never`. | ||
@see {@link IsNever} | ||
@example | ||
``` | ||
import type {IfNever} from 'type-fest'; | ||
type ShouldBeTrue = IfNever<never>; | ||
//=> true | ||
type ShouldBeBar = IfNever<'not never', 'foo', 'bar'>; | ||
//=> 'bar' | ||
``` | ||
@category Type Guard | ||
@category Utilities | ||
*/ | ||
type IfNever<T, TypeIfNever = true, TypeIfNotNever = false> = ( | ||
IsNever<T> extends true ? TypeIfNever : TypeIfNotNever | ||
); | ||
/** | ||
Extract the keys from a type where the value type of the key extends the given `Condition`. | ||
@@ -308,17 +378,15 @@ | ||
*/ | ||
type ConditionalKeys<Base, Condition> = NonNullable< | ||
// Wrap in `NonNullable` to strip away the `undefined` type from the produced union. | ||
type ConditionalKeys<Base, Condition> = | ||
{ | ||
// Map through all the keys of the given base type. | ||
[Key in keyof Base]: | ||
[Key in keyof Base]-?: | ||
// Pick only keys with types extending the given `Condition` type. | ||
Base[Key] extends Condition | ||
// Retain this key since the condition passes. | ||
? Key | ||
// Retain this key | ||
// If the value for the key extends never, only include it if `Condition` also extends never | ||
? IfNever<Base[Key], IfNever<Condition, Key, never>, Key> | ||
// Discard this key since the condition fails. | ||
: never; | ||
// Convert the produced object into a union type of the keys which passed the conditional test. | ||
}[keyof Base] | ||
>; | ||
}[keyof Base]; | ||
@@ -325,0 +393,0 @@ /** |
102316
24
2521
+ Added@wix/data-backend-public-sdk-poc_data@1.0.31(transitive)
- Removed@babel/runtime@7.26.0(transitive)
- Removed@rushstack/eslint-patch@1.10.4(transitive)
- Removed@wix/data-backend-public-sdk-poc_data@1.0.30(transitive)
- Removed@wix/filter-builder@1.0.93(transitive)
- Removed@wix/metro-public-utils@1.0.36(transitive)
- Removed@wix/metro-runtime@1.1879.0(transitive)
- Removed@wix/motion-edm-autogen-common@1.51.0(transitive)
- Removed@wix/motion-edm-autogen-p13n@1.0.87(transitive)
- Removed@wix/motion-edm-autogen-query-wrapper@1.0.123(transitive)
- Removed@wix/motion-edm-autogen-transformations@1.61.0(transitive)
- Removed@wix/motion-edm-autogen-transformations-core@1.55.0(transitive)
- Removed@wix/motion-edm-autogen-types@1.0.39(transitive)
- Removedargparse@2.0.1(transitive)
- Removedconstant-case@3.0.4(transitive)
- Removeddeep-for-each@3.0.0(transitive)
- Removedhttp-status-codes@2.3.0(transitive)
- Removedjs-base64@3.7.7(transitive)
- Removedjs-yaml@4.1.0(transitive)
- Removedjsonpath-plus@5.1.0(transitive)
- Removedkind-of@5.1.0(transitive)
- Removedlodash@4.17.21(transitive)
- Removedlodash.isplainobject@4.0.6(transitive)
- Removedlong@4.0.0(transitive)
- Removedlower-case@2.0.2(transitive)
- Removedno-case@3.0.4(transitive)
- Removedquerystring@0.2.1(transitive)
- Removedregenerator-runtime@0.14.1(transitive)
- Removedtslib@2.8.1(transitive)
- Removedupper-case@2.0.2(transitive)