Skip to content

Commit fdf8d3e

Browse files
committed
Add screen_view updates
1 parent ce1efb1 commit fdf8d3e

File tree

4 files changed

+16
-32
lines changed

4 files changed

+16
-32
lines changed

packages-exp/analytics-exp/src/api.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -439,21 +439,13 @@ export function logEvent(
439439
* automatically associates this logged event with this Firebase web
440440
* app instance on this device.
441441
* @public
442-
* See
443-
* {@link https://developers.google.com/analytics/devguides/collection/ga4/screen-view
444-
* | Screen views}.
445442
*/
446443
export function logEvent(
447444
analyticsInstance: Analytics,
448445
eventName: 'screen_view',
449446
eventParams?: {
450-
app_name: string;
451-
screen_name: EventParams['screen_name'];
452447
firebase_screen: EventParams['firebase_screen'];
453448
firebase_screen_class: EventParams['firebase_screen_class'];
454-
app_id?: string;
455-
app_version?: string;
456-
app_installer_id?: string;
457449
[key: string]: any;
458450
},
459451
options?: AnalyticsCallOptions

packages-exp/firebase-exp/compat/index.d.ts

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4887,18 +4887,14 @@ declare namespace firebase.analytics {
48874887
* Sends analytics event with given `eventParams`. This method
48884888
* automatically associates this logged event with this Firebase web
48894889
* app instance on this device.
4890-
* See
4891-
* {@link https://developers.google.com/analytics/devguides/collection/ga4/screen-view
4892-
* | Screen views}.
4890+
* See {@link https://firebase.google.com/docs/analytics/screenviews
4891+
* | Track Screenviews}.
48934892
*/
48944893
logEvent(
48954894
eventName: 'screen_view',
48964895
eventParams?: {
4897-
app_name: string;
4898-
screen_name: EventParams['screen_name'];
4899-
app_id?: string;
4900-
app_version?: string;
4901-
app_installer_id?: string;
4896+
firebase_screen: EventParams['firebase_screen'];
4897+
firebase_screen_class: EventParams['firebase_screen_class'];
49024898
[key: string]: any;
49034899
},
49044900
options?: firebase.analytics.AnalyticsCallOptions
@@ -5197,6 +5193,14 @@ declare namespace firebase.analytics {
51975193
currency?: string;
51985194
description?: string;
51995195
fatal?: boolean;
5196+
/**
5197+
* Firebase-specific. Use to log a `screen_name` to Firebase Analytics.
5198+
*/
5199+
firebase_screen?: string;
5200+
/**
5201+
* Firebase-specific. Use to log a `screen_class` to Firebase Analytics.
5202+
*/
5203+
firebase_screen_class?: string;
52005204
items?: Item[];
52015205
method?: string;
52025206
number?: string;

packages/analytics-types/index.d.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -239,20 +239,14 @@ export interface FirebaseAnalytics {
239239
* Sends analytics event with given `eventParams`. This method
240240
* automatically associates this logged event with this Firebase web
241241
* app instance on this device.
242-
* See
243-
* {@link https://developers.google.com/analytics/devguides/collection/ga4/screen-view
244-
* | Screen views}.
242+
* See {@link https://firebase.google.com/docs/analytics/screenviews
243+
* | Track Screenviews}.
245244
*/
246245
logEvent(
247246
eventName: 'screen_view',
248247
eventParams?: {
249-
app_name: string;
250-
screen_name: EventParams['screen_name'];
251248
firebase_screen: EventParams['firebase_screen'];
252249
firebase_screen_class: EventParams['firebase_screen_class'];
253-
app_id?: string;
254-
app_version?: string;
255-
app_installer_id?: string;
256250
[key: string]: any;
257251
},
258252
options?: AnalyticsCallOptions

packages/firebase/index.d.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4849,20 +4849,14 @@ declare namespace firebase.analytics {
48494849
* Sends analytics event with given `eventParams`. This method
48504850
* automatically associates this logged event with this Firebase web
48514851
* app instance on this device.
4852-
* See
4853-
* {@link https://developers.google.com/analytics/devguides/collection/ga4/screen-view
4854-
* | Screen views}.
4852+
* See {@link https://firebase.google.com/docs/analytics/screenviews
4853+
* | Track Screenviews}.
48554854
*/
48564855
logEvent(
48574856
eventName: 'screen_view',
48584857
eventParams?: {
4859-
app_name: string;
4860-
screen_name: EventParams['screen_name'];
48614858
firebase_screen: EventParams['firebase_screen'];
48624859
firebase_screen_class: EventParams['firebase_screen_class'];
4863-
app_id?: string;
4864-
app_version?: string;
4865-
app_installer_id?: string;
48664860
[key: string]: any;
48674861
},
48684862
options?: firebase.analytics.AnalyticsCallOptions

0 commit comments

Comments
 (0)