From 7e9b2594a646ce30f93838e2e95e73a9eeba576c Mon Sep 17 00:00:00 2001 From: Lukasz Ostrowski Date: Tue, 17 Dec 2024 11:53:56 +0100 Subject: [PATCH] vercel kv exported as non-experimental (#372) * vercel kv exported as non-experimental * deprecate old symbol * remove not needed variable * better deprecation * restore required var * docs --- .changeset/fuzzy-pans-develop.md | 5 +++++ src/APL/vercel-kv/index.ts | 14 ++++++++++++-- src/APL/vercel-kv/vercel-kv-apl.ts | 2 +- 3 files changed, 18 insertions(+), 3 deletions(-) create mode 100644 .changeset/fuzzy-pans-develop.md diff --git a/.changeset/fuzzy-pans-develop.md b/.changeset/fuzzy-pans-develop.md new file mode 100644 index 00000000..91b38fe8 --- /dev/null +++ b/.changeset/fuzzy-pans-develop.md @@ -0,0 +1,5 @@ +--- +"@saleor/app-sdk": minor +--- + +Added VercelKV APL. It provides out-of-the-box integration. See [docs](https://docs.saleor.io/developer/extending/apps/developing-apps/app-sdk/apl#vercelkvapl) diff --git a/src/APL/vercel-kv/index.ts b/src/APL/vercel-kv/index.ts index ed452e29..92dc6ffc 100644 --- a/src/APL/vercel-kv/index.ts +++ b/src/APL/vercel-kv/index.ts @@ -1,2 +1,12 @@ -// eslint-disable-next-line camelcase -export { VercelKvApl as _experimental_VercelKvApl } from "./vercel-kv-apl"; +import { VercelKvApl } from "./vercel-kv-apl"; + +/** + * @deprecated - use VercelKvApl + */ +const _experimental_VercelKvApl = VercelKvApl; + +export { + // TODO Remove in next minor + _experimental_VercelKvApl, + VercelKvApl, +}; diff --git a/src/APL/vercel-kv/vercel-kv-apl.ts b/src/APL/vercel-kv/vercel-kv-apl.ts index bab2ad16..cd1ac0fb 100644 --- a/src/APL/vercel-kv/vercel-kv-apl.ts +++ b/src/APL/vercel-kv/vercel-kv-apl.ts @@ -199,11 +199,11 @@ export class VercelKvApl implements APL { private envVariablesRequiredByKvExist() { const variables = [ - "KV_URL", "KV_REST_API_URL", "KV_REST_API_TOKEN", "KV_REST_API_READ_ONLY_TOKEN", "KV_STORAGE_NAMESPACE", + "KV_URL", ]; return variables.every((variable) => !!process.env[variable]);