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

mozilla / blurts-server / c5f3d7b4-ee0c-44dd-8229-fb0a50cc276f

pending completion
c5f3d7b4-ee0c-44dd-8229-fb0a50cc276f

Pull #2987

circleci

Amri Toufali
add ESLint plugin for camelCase lint
Pull Request #2987: MNTOR-1171: Code Splitting

282 of 1663 branches covered (16.96%)

Branch coverage included in aggregate %.

12 of 12 new or added lines in 9 files covered. (100.0%)

959 of 4511 relevant lines covered (21.26%)

3.55 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/client/js/appConstants.js
1
/* This Source Code Form is subject to the terms of the Mozilla Public
2
 * License, v. 2.0. If a copy of the MPL was not distributed with this
3
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4

5
// PUBLIC APP CONSTANTS – DO NOT ADD SECRETS HERE
6

7
/* During build-phase (npm start), ESBuild creates `buildConstants` as defined in esbuild.js, which include server env vars.
8
These are merged into client AppConstants and exported.
9

10
When app is run via `npm run dev`, ESBuild does not run and `buildConstants` is undefined.
11
For this case, we can add fallback vars to AppConstants if needed for testing. */
12

13
/* global buildConstants */
14

15
const AppConstants = {}
×
16

17
if (typeof buildConstants === 'object') {
×
18
  // Build-phase has run (npm start) and ESBuild defined `buildConstants` object
19
  Object.assign(AppConstants, buildConstants)
×
20
} else {
21
  // Build-phase was not run (npm run dev). Assign fallbacks for testing if needed.
22
  Object.assign(AppConstants, {
×
23
    GA4_MEASUREMENT_ID: 'G-CXG8K4KW4P'
24
  })
25
  console.log('Running dev-mode with fallback values for AppConstants.')
×
26
}
27

28
export default Object.freeze(AppConstants)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc