Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add @flags-sdk/supaship adapter#337

Open
madhusudhand wants to merge 1 commit into
vercel:main from
madhusudhand:supaship-adapter
Open

Add @flags-sdk/supaship adapter #337
madhusudhand wants to merge 1 commit into
vercel:main from
madhusudhand:supaship-adapter

Conversation

@madhusudhand

@madhusudhand madhusudhand commented Mar 18, 2026
edited
Loading

Copy link
Copy Markdown

Summary

This PR introduces a Supaship adapter for the Flags SDK via a new @flags-sdk/supaship package, along with tests and documentation.

It also adds Supaship to the providers catalog in the docs so users can discover and use it as a flag provider.

Motivation

The Flags SDK is designed to support multiple providers through a consistent adapter interface. This PR extends that ecosystem by enabling Supaship as a compatible provider.

This allows teams using Supaship to adopt the Flags SDK without changing their flag evaluation patterns.

Changes

New adapter package: @flags-sdk/supaship

  • Added new package scaffolding and build/test configuration:
    • package.json
    • tsconfig.json
    • tsup.config.js
    • vitest.config.ts
    • CHANGELOG.md
  • Added runtime adapter implementation in packages/adapter-supaship/src/index.ts:
    • createSupashipAdapter(...) factory
    • default lazy singleton supashipAdapter
    • typed exports for Supaship context/value/plugin/network types
    • feature().decide(...) flow that:
      • merges static adapter context + per-call context + request entities
      • resolves values through Supaship client
      • falls back to defaultValue on null/undefined
      • throws a clear error if no value and no default are provided
  • Added test coverage in packages/adapter-supaship/src/index.test.ts for:
    • default client config creation
    • context/entity merge behavior
    • fallback behavior for undefined and null
    • error path when no defaultValue exists
    • default adapter env-var validation
    • lazy initialization (single client creation across calls)

Documentation updates

  • Added provider page: apps/docs/content/docs/providers/supaship.mdx
    • install/setup instructions
    • default and custom adapter usage
    • identify/context example for Next.js
    • feature() usage example
    • links to source and Supaship SDK
  • Added Supaship to provider navigation metadata:
    • apps/docs/content/docs/providers/meta.json
  • Added Supaship branding to provider list:
    • new logo component apps/docs/components/custom/logos/supaship.tsx
    • provider card entry in apps/docs/components/custom/provider-list.tsx

Dependency/lockfile updates

  • Added @supashiphq/javascript-sdk@1.0.0 to package graph for the new adapter package.
  • Commit also includes lockfile.

Test plan

  • pnpm --filter @flags-sdk/supaship test
  • pnpm --filter @flags-sdk/supaship type-check
  • pnpm --filter @flags-sdk/supaship build
  • pnpm --filter docs dev and verify Supaship appears in provider list and docs page renders/examples are correct

vercel Bot commented Mar 18, 2026

Copy link
Copy Markdown
Contributor

@madhusudhand is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

socket-security Bot commented Mar 18, 2026
edited
Loading

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated react@​19.3.0-canary-46103596-20260305 ⏵ 19.3.0-canary-c80a0750-20260312 100 100 84 98 100

View full report

Comment thread apps/docs/content/docs/providers/supaship.mdx Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@vercel vercel[bot] vercel[bot] left review comments

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /