Skip to content

Commit 74bd3ce

Browse files
fix init parameter name
1 parent 4845699 commit 74bd3ce

2 files changed

Lines changed: 10 additions & 10 deletions

File tree

packages/browser-rum-core/src/domain/configuration/configuration.spec.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ describe('validateAndBuildRumConfiguration', () => {
333333
const configuration = validateAndBuildRumConfiguration(DEFAULT_INIT_CONFIGURATION)!
334334

335335
expect(configuration.enableSessionReplayCanvasRecording).toBeFalse()
336-
expect(configuration.sessionReplayMaxCanvasFPS).toBe(0)
336+
expect(configuration.sessionReplayMaxCanvasFps).toBe(0)
337337
})
338338

339339
it('stays disabled when requested without the experimental feature', () => {
@@ -343,7 +343,7 @@ describe('validateAndBuildRumConfiguration', () => {
343343
})!
344344

345345
expect(configuration.enableSessionReplayCanvasRecording).toBeFalse()
346-
expect(configuration.sessionReplayMaxCanvasFPS).toBe(0)
346+
expect(configuration.sessionReplayMaxCanvasFps).toBe(0)
347347
})
348348

349349
describe('when the experimental feature is enabled', () => {
@@ -358,17 +358,17 @@ describe('validateAndBuildRumConfiguration', () => {
358358
})!
359359

360360
expect(configuration.enableSessionReplayCanvasRecording).toBeTrue()
361-
expect(configuration.sessionReplayMaxCanvasFPS).toBe(1)
361+
expect(configuration.sessionReplayMaxCanvasFps).toBe(1)
362362
})
363363

364364
it('uses the configured frame rate', () => {
365365
const configuration = validateAndBuildRumConfiguration({
366366
...DEFAULT_INIT_CONFIGURATION,
367367
enableSessionReplayCanvasRecording: true,
368-
sessionReplayMaxCanvasFPS: 2.5,
368+
sessionReplayMaxCanvasFps: 2.5,
369369
})!
370370

371-
expect(configuration.sessionReplayMaxCanvasFPS).toBe(2.5)
371+
expect(configuration.sessionReplayMaxCanvasFps).toBe(2.5)
372372
})
373373
})
374374
})
@@ -924,7 +924,7 @@ describe('serializeRumConfiguration', () => {
924924
betaEnableViewUpdates: true,
925925
betaTrackWebSockets: false,
926926
enableSessionReplayCanvasRecording: true,
927-
sessionReplayMaxCanvasFPS: 2.5,
927+
sessionReplayMaxCanvasFps: 2.5,
928928
}
929929

930930
type MapRumInitConfigurationKey<Key extends string> = Key extends keyof InitConfiguration
@@ -945,7 +945,7 @@ describe('serializeRumConfiguration', () => {
945945
| 'subdomain'
946946
| 'remoteConfiguration'
947947
| 'enableSessionReplayCanvasRecording'
948-
| 'sessionReplayMaxCanvasFPS'
948+
| 'sessionReplayMaxCanvasFps'
949949
? never
950950
: CamelToSnakeCase<Key>
951951
// By specifying the type here, we can ensure that serializeConfiguration is returning an

packages/browser-rum-core/src/domain/configuration/configuration.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ export interface RumInitConfiguration extends InitConfiguration {
230230
* @defaultValue 1
231231
* @hidden
232232
*/
233-
sessionReplayMaxCanvasFPS?: number | undefined
233+
sessionReplayMaxCanvasFps?: number | undefined
234234

235235
/**
236236
* Enables privacy control for action names.
@@ -416,7 +416,7 @@ export const RUM_SCHEMA = {
416416
propagateTraceBaggage: { type: 'boolean', default: true },
417417
startSessionReplayRecordingManually: { type: 'boolean', default: false, strict: false },
418418
enableSessionReplayCanvasRecording: { type: 'boolean', default: false },
419-
sessionReplayMaxCanvasFPS: { type: 'number', min: 0, max: 5, default: 1 },
419+
sessionReplayMaxCanvasFps: { type: 'number', min: 0, max: 5, default: 1 },
420420

421421
// Enums
422422
defaultPrivacyLevel: {
@@ -516,7 +516,7 @@ export function validateAndBuildRumConfiguration(
516516
return {
517517
...config,
518518
enableSessionReplayCanvasRecording,
519-
sessionReplayMaxCanvasFPS: enableSessionReplayCanvasRecording ? config.sessionReplayMaxCanvasFPS : 0,
519+
sessionReplayMaxCanvasFps: enableSessionReplayCanvasRecording ? config.sessionReplayMaxCanvasFps : 0,
520520
allowedTracingUrls,
521521
beforeSend: config.beforeSend
522522
? (catchUserErrors(config.beforeSend, 'beforeSend threw an error:') as typeof config.beforeSend)

0 commit comments

Comments
 (0)