Skip to content

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

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

Open
wants to merge 27 commits into
base: next
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
665e247
Update README.md
dackers86 Aug 20, 2024
da189b5
fix(deps): Update for ES Module compatibility
trentrand Nov 27, 2024
5c04bea
Refactor postbuild script to remove require statement and dependencies
trentrand Nov 27, 2024
528d97e
chore: Update version to next patch 0.0.8
trentrand Nov 27, 2024
32d1577
refactor: rename package namespace
trentrand Nov 27, 2024
ec22303
chore: link published NPM package to repository
trentrand Nov 27, 2024
46b3033
refactor: migrate from namespaced to modular Firebase API
trentrand Nov 27, 2024
239ba0f
refactor: replace NPM with Bun
trentrand Nov 27, 2024
830524a
chore: remove ownership transfer notice from README
trentrand Nov 28, 2024
0caf1bf
chore: remove deprecated package directory
trentrand Nov 28, 2024
cd31d3e
docs: update contributing guidelines and remove code of conduct
trentrand Nov 28, 2024
979e1f8
Update Stripe SDK and add marketing_features field to Product
trentrand Nov 29, 2024
f817621
Prepare package for 0.0.8 release
trentrand Dec 2, 2024
25300aa
Fix test import statements
trentrand Dec 3, 2024
6f64a78
Upgrade firestore library to latest version
trentrand Dec 16, 2024
9a9a207
Update README with published package link
trentrand Dec 16, 2024
fc814aa
0.0.9
trentrand Dec 16, 2024
011363e
feat: bump to Node.js 20 runtimes (#657)
cabljac Apr 10, 2025
d998f8a
Update firebase to v11.6.0
trentrand Apr 11, 2025
584d936
0.0.10
trentrand Apr 11, 2025
8693a47
Specify firebase as peer dependency
trentrand Apr 11, 2025
ea3f3ec
0.0.11
trentrand Apr 11, 2025
3c323e8
Pass-through metadata from Firebase Functions to new Stripe account
trentrand Apr 20, 2025
506f717
Add package-lock.json for Firebase Extensions publishing
trentrand Apr 20, 2025
113b580
Add script to publish new version to Firebase Extension Registry
trentrand Apr 20, 2025
dc79d68
Revert "Fix test import statements"
trentrand Apr 20, 2025
565973e
firestore-stripe-payments extension 0.4.3
trentrand Apr 20, 2025
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
19 changes: 6 additions & 13 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,10 @@ jobs:
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: false
strategy:
matrix:
node: ["18"]
max-parallel: 1
name: node.js_${{ matrix.node }}_test
name: bun_test
steps:
- uses: actions/checkout@v3
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- uses: oven-sh/setup-bun@v2

- name: Install cloudflared
run: |
Expand All @@ -37,19 +30,19 @@ jobs:
sudo apt-get install -f
shell: /usr/bin/bash -e {0}

- name: NPM install
run: npm install
- name: Bun install
run: bun install
- name: Install firebase CLI
uses: nick-invision/retry@v2
with:
timeout_minutes: 10
retry_wait_seconds: 60
max_attempts: 3
command: npm i -g firebase-tools
command: bun i -g firebase-tools
- name: mask env paramaters
run: echo "::add-mask::$STRIPE_WEBHOOK_SECRET"
- name: Run tests with coverage
run: npm run test
run: bun test
env:
STRIPE_API_KEY: ${{ secrets.STRIPE_API_KEY }}
STRIPE_WEBHOOK_SECRET: ${{ secrets.STRIPE_WEBHOOK_SECRET }}
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: NPM Install & Build
run: npm i
- uses: oven-sh/setup-bun@v2
- name: Bun Install
run: bun i
- name: Prettier Lint Check
run: npm run lint
run: bun run lint
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ build
local.properties
coverage
package-lock.json
yarn.lock
yarn.lock
firestore-stripe-payments/_emulator/extensions/firestore-stripe-payments.secret.local
76 changes: 0 additions & 76 deletions CODE_OF_CONDUCT.md

This file was deleted.

17 changes: 4 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@

We highly appreciate feedback and contributions from the community! If you'd like to contribute to this project, please make sure to review and follow the guidelines below.

## Code of conduct

In the interest of fostering an open and welcoming environment, please review and follow our [code of conduct](./CODE_OF_CONDUCT.md).

## Code and copy reviews

All submissions, including submissions by project members, require review. We
Expand All @@ -15,25 +11,20 @@ information on using pull requests.

## Report an issue

Report all issues through GitHub Issues using the [Report a Bug](https://github.com/stripe/stripe-firebase-extensions/issues/new?template=1.Bug_report.md) template.
Report all issues through GitHub Issues using the [Report a Bug](https://github.com/trentrand/stripe-firebase-extensions/issues/new?template=1.Bug_report.md) template.

To help resolve your issue as quickly as possible, read the template and provide all the requested information.

## File a feature request

We welcome all feature requests, whether it's to add new functionality to an existing extension or to offer an idea for a brand new extension.

File your feature request through GitHub Issues using the [Feature Request template](https://github.com/stripe/stripe-firebase-extensions/issues/new?template=2.Feature_request.md).
File your feature request through GitHub Issues using the [Feature Request template](https://github.com/trentrand/stripe-firebase-extensions/issues/new?template=2.Feature_request.md).

## Create a pull request

When making pull requests to the repository, make sure to follow these guidelines for both bug fixes and new features:
When making pull requests to the repository, consider following these guidelines for both bug fixes and new features:

- Before creating a pull request, file a GitHub Issue so that maintainers and the community can discuss the problem and potential solutions before you spend time on an implementation.
- In your PR's description, link to any related issues or pull requests to give reviewers the full context of your change.
- For commit messages, follow the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) format.
- For example, if you update documentation for a specific extension, your commit message might be: `docs(extension-name) updated installation documentation`.

### Features

Before creating pull requests for new features, first file a GitHub Issue describing the reasoning and motivation for the feature. This gives maintainers and the community the opportunity to provide feedback on your idea before implementing it.
- For example, if you update documentation for a specific extension, your commit message might be: `docs(extension-name) updated installation documentation`.
11 changes: 4 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
# UPDATE 2023-10-08:
This project has now being officailly transferred to [Invertase](https://github.com/invertase), who will maintain this extension going forward. Please see [this issue](https://github.com/stripe/stripe-firebase-extensions/issues/524) for more details.
It is now reccomended to uninstall the `stripe/firestore-stripe-payments` extension and install `invertase/firestore-stripe-payments` from the Firebase Extension Hub.

Alternativley, you can also use the following link to convert your current installation to the Invertase version
# Stripe Firebase Extensions

`https://console.firebase.google.com/project/_/extensions/install?instanceId=STRIPE_EXTENSION_INSTANCE_ID&ref=invertase%[email protected]`
> The original @firebase/firestore-stripe-payments package was officially transferred to Invertase, but they do a lousy job of maintaining it. Critical PRs have been open for over two years.
> Use this version if you'd like ESM compatibility and a number of other improvements.

# Stripe Firebase Extensions
**Install the web SDK from npm** [`@trentrand/firestore-stripe-payments`](https://www.npmjs.com/package/@trentrand/firestore-stripe-payments)

This repository contains the source code for Firebase Extensions that enable payment functionality. Created and tested by Stripe, these official Stripe Firebase extensions are reliable and secure. To learn more about Firebase Extensions, including how to install them in your Firebase projects, visit the [Firebase documentation](https://firebase.google.com/docs/extensions).

Expand Down
Binary file added bun.lockb
Binary file not shown.
4 changes: 4 additions & 0 deletions firestore-stripe-invoices/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## Version 0.2.7 - 2025-03-24

[fix] - upgrade resources to node 20

### Version 0.2.6 - 2024-02-14

[feat] - Added `payments` tag to the extension to allow for easier discovery in the marketplace.
Expand Down
6 changes: 3 additions & 3 deletions firestore-stripe-invoices/extension.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

name: firestore-stripe-invoices
version: 0.2.6
version: 0.2.7
specVersion: v1beta

displayName: Send Invoices using Stripe
Expand Down Expand Up @@ -63,7 +63,7 @@ resources:
in your specified Cloud Firestore collection
properties:
location: ${LOCATION}
runtime: nodejs18
runtime: nodejs20
eventTrigger:
eventType: providers/cloud.firestore/eventTypes/document.create
resource: projects/${PROJECT_ID}/databases/(default)/documents/${INVOICES_COLLECTION}/{id}
Expand All @@ -76,7 +76,7 @@ resources:
a new Stripe Event is received.
properties:
location: ${LOCATION}
runtime: nodejs18
runtime: nodejs20
httpsTrigger: {}

params:
Expand Down
Loading