Skip to content

Commit b62df73

Browse files
committed
Fixed the example Job trigger file import path when using Pages Router with no path alias
1 parent e347389 commit b62df73

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/shaggy-adults-return.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@trigger.dev/cli": patch
3+
---
4+
5+
Fixed the example Job trigger file import path when using Pages Router with no path alias

packages/cli/src/commands/init.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,7 @@ async function createTriggerPageRoute(
567567
const { tsconfig } = await parse(tsConfigPath);
568568

569569
const pathAlias = getPathAlias(tsconfig, usesSrcDir);
570-
const routePathPrefix = pathAlias ? pathAlias + "/" : "../..";
570+
const routePathPrefix = pathAlias ? pathAlias + "/" : "../../";
571571

572572
const extension = isTypescriptProject ? ".ts" : ".js";
573573
const triggerFileName = `trigger${extension}`;

0 commit comments

Comments
 (0)