Skip to content

Commit

Permalink
fix(actions): explicitly import index.ts to fix types when moduleReso…
Browse files Browse the repository at this point in the history
…lution is NodeNext (#12578)
  • Loading branch information
WesSouza authored Dec 2, 2024
1 parent b139390 commit 07b9ca8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/empty-jobs-impress.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'astro': patch
---

Explicitly import index.ts to fix types when moduleResolution is NodeNext
2 changes: 1 addition & 1 deletion packages/astro/src/actions/integration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export default function astroIntegrationActionsRouteHandler({
}

const stringifiedActionsImport = JSON.stringify(
viteID(new URL('./actions', params.config.srcDir)),
viteID(new URL('./actions/index.ts', params.config.srcDir)),
);
settings.injectedTypes.push({
filename: ACTIONS_TYPES_FILE,
Expand Down

0 comments on commit 07b9ca8

Please sign in to comment.