Skip to content

Commit

Permalink
Add link to Track Screenviews dev doc.
Browse files Browse the repository at this point in the history
  • Loading branch information
dwyfrequency committed May 16, 2022
1 parent a09d26c commit f561e54
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/analytics-compat/src/service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,10 @@ export class AnalyticsService implements FirebaseAnalytics, _FirebaseService {
logEventExp(this._delegate, eventName as '', eventParams, options);
}

/** @deprecated Use {@link logEvent} with `eventName` as 'screen_view' and add relevant `eventParams`. */
/**
* @deprecated Use {@link logEvent} with `eventName` as 'screen_view' and add relevant `eventParams`.
* See {@link https://firebase.google.com/docs/analytics/screenviews | Track Screenviews}.
*/
setCurrentScreen(screenName: string, options?: AnalyticsCallOptions): void {
setCurrentScreenExp(this._delegate, screenName, options);
}
Expand Down
1 change: 1 addition & 0 deletions packages/analytics-types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,7 @@ export interface FirebaseAnalytics {
* Use gtag 'config' command to set 'screen_name'.
*
* @deprecated Use {@link logEvent} with `eventName` as 'screen_view' and add relevant `eventParams`.
* See {@link https://firebase.google.com/docs/analytics/screenviews | Track Screenviews}.
*/
setCurrentScreen(screenName: string, options?: AnalyticsCallOptions): void;

Expand Down
1 change: 1 addition & 0 deletions packages/analytics/src/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ export async function isSupported(): Promise<boolean> {
* @public
*
* @deprecated Use {@link logEvent} with `eventName` as 'screen_view' and add relevant `eventParams`.
* See {@link https://firebase.google.com/docs/analytics/screenviews | Track Screenviews}.
*
* @param analyticsInstance - The {@link Analytics} instance.
* @param screenName - Screen name to set.
Expand Down
1 change: 1 addition & 0 deletions packages/analytics/src/functions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export async function logEvent(
* Set screen_name parameter for this Google Analytics ID.
*
* @deprecated Use {@link logEvent} with `eventName` as 'screen_view' and add relevant `eventParams`.
* See {@link https://firebase.google.com/docs/analytics/screenviews | Track Screenviews}.
*
* @param gtagFunction Wrapped gtag function that waits for fid to be set before sending an event
* @param screenName Screen name string to set.
Expand Down
1 change: 1 addition & 0 deletions packages/firebase/compat/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5217,6 +5217,7 @@ declare namespace firebase.analytics {
* Use gtag 'config' command to set 'screen_name'.
*
* @deprecated Use {@link logEvent} with `eventName` as 'screen_view' and add relevant `eventParams`.
* See {@link https://firebase.google.com/docs/analytics/screenviews | Track Screenviews}.
*/
setCurrentScreen(
screenName: string,
Expand Down

0 comments on commit f561e54

Please sign in to comment.