You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@pipedream/types

Package Overview
Dependencies
Maintainers
9
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pipedream/types - npm Package Compare versions

Comparing version

to
0.3.2

10

dist/index.d.ts

@@ -267,3 +267,2 @@ /// <reference types="node" />

};
type Modify<T, R> = Omit<T, keyof R> & R;
interface BaseSource<Methods, SourcePropDefinitions> {

@@ -282,7 +281,10 @@ key: string;

}
export type DedupedSource<Methods, SourcePropDefinitions> = Modify<BaseSource<Methods, SourcePropDefinitions>, {
export interface DedupedSource<Methods, SourcePropDefinitions> extends BaseSource<Methods, SourcePropDefinitions> {
dedupe: "last" | "greatest" | "unique";
run: (this: PropThis<SourcePropDefinitions> & Methods & IdEmitFunction, options?: SourceRunOptions) => void | Promise<void>;
}>;
export type Source<Methods, SourcePropDefinitions> = DedupedSource<Methods, SourcePropDefinitions>;
}
export interface NonDedupedSource<Methods, SourcePropDefinitions> extends BaseSource<Methods, SourcePropDefinitions> {
dedupe?: never;
}
export type Source<Methods, SourcePropDefinitions> = DedupedSource<Methods, SourcePropDefinitions> | NonDedupedSource<Methods, SourcePropDefinitions>;
export declare function defineSource<Methods, SourcePropDefinitions>(component: Source<Methods, SourcePropDefinitions>): Source<Methods, SourcePropDefinitions>;

@@ -289,0 +291,0 @@ export interface Action<Methods, ActionPropDefinitions> {

@@ -256,2 +256,35 @@ "use strict";

};
const nonDedupedSource = {
key: "source",
name: "Test Source",
description: "hello, world",
version: "0.0.1",
type: "source",
async run() {
this.$emit({
foo: "bar ",
}, {
name: "channel",
summary: "Summary",
ts: 123,
});
},
};
const nonDedupedSourceWithId = {
key: "source",
name: "Test Source",
description: "hello, world",
version: "0.0.1",
type: "source",
async run() {
this.$emit({
foo: "bar ",
}, {
id: 246,
name: "channel",
summary: "Summary",
ts: 123,
});
},
};
// Bad sources

@@ -258,0 +291,0 @@ // @ts-expect-error $ExpectError - Missing key

2

package.json
{
"name": "@pipedream/types",
"version": "0.3.1",
"version": "0.3.2",
"description": "Pipedream TypeScript types",

@@ -5,0 +5,0 @@ "keywords": [