Skip to content
This repository was archived by the owner on Jun 18, 2026. It is now read-only.

fix(deps): Update for ES Module compatibility#645

Open
trentrand wants to merge 27 commits into
invertase:nextfrom
trentrand:next
Open

fix(deps): Update for ES Module compatibility#645
trentrand wants to merge 27 commits into
invertase:nextfrom
trentrand:next

Conversation

@trentrand

Copy link
Copy Markdown

Added "type": "module" and .js extensions to imports. This aligns the library with requirements for ECMAScript Modules, which are now widely adopted.

dackers86 and others added 2 commits August 20, 2024 17:41
Added "type": "module" and .js extensions to imports. This aligns the library with requirements for ECMAScript Modules, which are now widely adopted.
@CLAassistant

CLAassistant commented Nov 27, 2024

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@trentrand

Copy link
Copy Markdown
Author

Resolves #440. Without these changes, the dependency is unusable in newer versions of Vite. Therefor it prohibits use in Vue, Nuxt 3, SvelteKit, Remix, Analog, Angular, Astro, SolidJS, Qwik City, RedwoodJS.

@trentrand

Copy link
Copy Markdown
Author

This fix has been published as @trentrand/stripe-firebase-extensions@0.0.8.

See my fork, which additionally updates the package to the latest Stripe API (+ 2 years), uses modular Firebase package (firebase instead of many firebase/*), ECMAScript Modules (ESM), and Bun build tooling for faster development.

https://github.com/trentrand/stripe-firebase-extensions

@agoransson

Copy link
Copy Markdown

This really helped me! Thanks a lot @trentrand

cabljac and others added 5 commits April 11, 2025 15:31
* feat: bump to Node.js 20 runtimes

* chore: run npm audit fix

* chore: rename sensitive example file

* chore: add secret file to gitignore

* chore(CI): bump node in CI

* chore(CI): bump deps in web sdk to fix CI

Co-authored-by: Trent Rand <contact@trentrand.com>
Sometimes the consumer application would use a different instance of
Firebase, and so calls like `parent instanceOf Payment` would fail
because the two instances were technically from different modules.

The package should now share the consumers instance of Firebase.
You can call `createCheckoutSession` and `createPortalLink` with the
metadata parameter, and these will be saved as metadata fields for the
created Stripe user.
This reverts commit 25300aa.

The previous commit changed import statements for firebase-admin
and firebase-functions to default imports, which caused the extension
deployment to fail with runtime errors (Cannot read properties of
undefined (reading 'auth')). The correct usage is to use namespace
imports (import * as admin from 'firebase-admin'). This revert
restores the working import style and fixes the deployment issue.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

5 participants