Skip to content

Merge data connectors into a single data-connector#152

Merged
dijimsta merged 1 commit into
mainfrom
add-accounts-web-connector
Jul 6, 2026
Merged

Merge data connectors into a single data-connector#152
dijimsta merged 1 commit into
mainfrom
add-accounts-web-connector

Conversation

@dijimsta

@dijimsta dijimsta commented Jul 6, 2026

Copy link
Copy Markdown
Owner

Summary

  • Consolidates the accounts, example, and questionnaires Firebase Data Connect connectors into one connector at data/connector, generating combined @generated/data-connector-admin and @generated/data-connector-web (with a react subpackage) SDKs.
  • Account operations are now also exposed through the web SDK, alongside questionnaires (this is what the branch was originally started for).
  • Operations are split into domain-scoped .gql files (accounts, projects, quotes, reminders, users, questionnaires) within the single connector; UserSettings moves from data/schemas/accounts.gql into its own data/schemas/users.gql to match.
  • Removes functions/plaster-calculator-functions/src/data-connect.ts and its dataConnect argument at every call site — with only one connector left, the getDataConnect() caching workaround from Extract accounts connector from example connector #151 is no longer needed, so functions resolve the connector implicitly.
  • Converts all generated-SDK imports (functions, apps, libraries) from aliased named imports (e.g. createAccount as dcCreateAccount) to import * as DataConnector namespace imports.

Test plan

  • pnpm build, pnpm lint, pnpm format all pass (done locally, no errors, only 2 pre-existing unrelated max-lines warnings)
  • Verify the Data Connect emulator serves the merged connector correctly (pnpm emulators:start)
  • Smoke-test account, project, quote, reminder, and questionnaire flows against the emulator
  • Confirm firebase deploy --only dataconnect and the functions deploy workflow still pick up the right paths

🤖 Generated with Claude Code

Consolidates the accounts, example, and questionnaires Firebase Data
Connect connectors into one connector at data/connector, generating
combined @generated/data-connector-admin and @generated/data-connector-web
(with a react subpackage) SDKs. As a result, account operations are now
also available through the web SDK, alongside questionnaires.

Operations are split into domain-scoped .gql files (accounts, projects,
quotes, reminders, users, questionnaires) within the single connector, and
the UserSettings type moves from data/schemas/accounts.gql into its own
data/schemas/users.gql to match.

Since there is only one connector now, the getDataConnect() caching
workaround added in #151 (constructing a DataConnect instance per
connector to dodge firebase-admin's location/serviceId-keyed cache) is no
longer needed, so functions/plaster-calculator-functions/src/data-connect.ts
is removed; call sites let the generated functions resolve the connector
implicitly. Generated-SDK imports across functions, apps, and libraries now
use `import * as DataConnector` namespace imports instead of aliased named
imports, avoiding renames like `createAccount as dcCreateAccount`.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@dijimsta dijimsta enabled auto-merge (squash) July 6, 2026 13:29
@dijimsta dijimsta merged commit 6949fce into main Jul 6, 2026
7 checks passed
@dijimsta dijimsta deleted the add-accounts-web-connector branch July 6, 2026 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant