Skip to content

Commit

Permalink
fix(remix-server-runtime): make DataFunctionArgs a type alias (#7362)
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelDeBoey authored Sep 8, 2023
1 parent be6a30a commit 4f133c4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .changeset/small-impalas-invent.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@remix-run/dev": patch
---

[REMOVE] make `DataFunctionArgs` a type alias
9 changes: 3 additions & 6 deletions packages/remix-server-runtime/routeModules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,10 @@ export interface RouteModules<RouteModule> {
}

// Context is always provided in Remix, and typed for module augmentation support.
// RR also doesn't export DataFunctionArgs so we extend the two interfaces here
// RR also doesn't export DataFunctionArgs, so we extend the two interfaces here
// even tough they're identical under the hood
export interface DataFunctionArgs
extends RRActionFunctionArgs,
RRLoaderFunctionArgs {
context: AppLoadContext;
}
export type DataFunctionArgs = RRActionFunctionArgs<AppLoadContext> &
RRLoaderFunctionArgs<AppLoadContext>;

/**
* A function that handles data mutations for a route.
Expand Down

0 comments on commit 4f133c4

Please sign in to comment.