Skip to content

Commit b021aba

Browse files
committed
Add comment and changeset
1 parent 857630d commit b021aba

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

.changeset/slow-bobcats-clap.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@firebase/messaging': patch
3+
---
4+
5+
Add a CJS bundle for messaging/sw. This enables some SSR frameworks to run their Node.js pipelines without erroring.

packages/messaging/rollup.config.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,11 @@ const cjsBuilds = [
9090
],
9191
external: id => deps.some(dep => id === dep || id.startsWith(`${dep}/`))
9292
},
93-
// sw builds
93+
// sw build
94+
// TODO: This may no longer be necessary when we can provide ESM Node
95+
// builds (contingent on updating the `idb` dependency). When we add
96+
// ESM Node builds, test with Nuxt and other SSR frameworks to see if
97+
// this can then be removed.
9498
{
9599
input: 'src/index.sw.ts',
96100
output: { file: pkg['sw-main'], format: 'cjs', sourcemap: true },

0 commit comments

Comments
 (0)