Skip to content

Commit

Permalink
chore: mode DeepPartial implementation to a types forlder
Browse files Browse the repository at this point in the history
  • Loading branch information
brandomeniconi committed Dec 3, 2024
1 parent 96b2b53 commit cecc3ad
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
5 changes: 1 addition & 4 deletions packages/sqs-lambda/src/eventbridge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,7 @@ import {
SqsEventSourceProps,
} from "aws-cdk-lib/aws-lambda-event-sources";
import { Duration } from "aws-cdk-lib";

type DeepPartial<T> = {
[P in keyof T]?: T[P] extends object ? DeepPartial<T[P]> : T[P];
};
import { DeepPartial } from "./types";

export type EventBridgeSqsLambdaRuleProps = Required<
Pick<RuleProps, "eventBus" | "eventPattern" | "ruleName">
Expand Down
3 changes: 3 additions & 0 deletions packages/sqs-lambda/src/types/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export type DeepPartial<T> = {
[P in keyof T]?: T[P] extends object ? DeepPartial<T[P]> : T[P];
};

0 comments on commit cecc3ad

Please sign in to comment.