Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Download Javy plugin with Javy binary #5014

Merged
merged 1 commit into from
Dec 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/shy-steaks-lay.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@shopify/app': patch
---

Download Javy plugin ahead of time with Javy CLI
3 changes: 2 additions & 1 deletion packages/app/src/cli/services/function/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,8 @@
const javyRequired = app.allExtensions.some((ext) => ext.features.includes('function') && ext.isJavaScript)
if (javyRequired) {
const javy = javyBinary()
await downloadBinary(javy)
const plugin = javyPluginBinary()
await Promise.all([downloadBinary(javy), downloadBinary(plugin)])
}
}

Expand Down Expand Up @@ -285,7 +286,7 @@
}

export function jsExports(fun: ExtensionInstance<FunctionConfigType>) {
const targets = fun.configuration.targeting || []

Check warning on line 289 in packages/app/src/cli/services/function/build.ts

View workflow job for this annotation

GitHub Actions / ESLint Report Analysis

packages/app/src/cli/services/function/build.ts#L289

[@typescript-eslint/prefer-nullish-coalescing] Prefer using nullish coalescing operator (`??`) instead of a logical or (`||`), as it is a safer operator.
const withoutExport = targets.filter((target) => !target.export)
const withExport = targets.filter((target) => Boolean(target.export))

Expand Down
Loading