• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

ThePalaceProject / web-patron / 37025394249
27%

Build:
DEFAULT BRANCH: main
Ran 02 Oct 2026 03:15PM UTC
Jobs 1
Files 111
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

02 Oct 2026 03:13PM UTC coverage: 26.741% (+0.4%) from 26.324%
37025394249

push

github

web-flow
Integrate Firebase Analytics (PP-5196) (#206)

## Description

<!--- Describe your changes -->
Adds the Firebase Analytics SDK for capturing usage data. 

- New Firebase Analytics helpers (`firebase.ts`, `useFirebaseAnalytics`)
provide asynchronous, non-blocking utilities for loading the Firebase
Analytics SDK and logging custom events.
- On first page load, `firebase.init()` kicks off loading the SDK
asynchronously and queues events so that the app never has to wait for
the SDK to load. A shared `firebaseAnalytics` Promise stores the SDK at
module-level and makes it available to all the methods within
`firebase.ts`.
- __Per-library usage__ is captured whenever events are logged from
pages that are provided library data.
- `firebase.ts` keeps track of the most recently visited library and
adds `library.id` and `library.slug` as __custom event parameters__ on
every logged event and as session-persisting __user properties__, which
allows us to group events by library and segment users on a per-library
basis, respectively.
- `useFirebaseAnalytics` updates the SDK with the latest library
whenever library data changes. _Note_: Pages that are unspecific to a
library, like the multi-library home page, still log events even when no
specific library data is available.
- __Custom page view events__ are sent from `userFirebaseAnalytics`
whenever users navigate through the app. A new utility
(`stripCredentials`) strips any potential user credentials found on
login-related URLs before any page views are logged. Locale is also
added as a custom parameter.
- `logEvents` from `firebase.ts` can be used in the future to log any
custom events for more granular usage filtering in Firebase.
- __Feature Flags__: set `PALACE_CPW_FEATURE_FIREBASE_ANALYTICS=true`
along with a valid `FIREBASE_CONFIG` JSON string to track usage stats
using Firebase Analytics. It is off by default. While off, no attempts
are made to load the Firebase Analytics SDK. Both flags are documented
in t... (continued)

364 of 1782 branches covered (20.43%)

Branch coverage included in aggregate %.

16 of 21 new or added lines in 4 files covered. (76.19%)

780 of 2496 relevant lines covered (31.25%)

9.2 hits per line

Uncovered Changes

Lines Coverage ∆ File
5
30.0
-3.33% src/errors.ts
Jobs
ID Job ID Ran Files Coverage
1 37025394249.1 02 Oct 2026 03:15PM UTC 111
26.74
GitHub Action Run
Source Files on build 37025394249
  • Tree
  • List 111
  • Changed 7
  • Source Changed 0
  • Coverage Changed 7
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • f6765dc2 on github
  • Prev Build on main (#36756800194)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc