Back to Firebase Js Sdk

GtagConfigParams interface

docs-devsite/analytics.gtagconfigparams.md

12.12.15.9 KB
Original Source

Project: /docs/reference/js/_project.yaml Book: /docs/reference/_book.yaml page_type: reference

{% comment %} DO NOT EDIT THIS FILE! This is generated by the JS SDK team, and any local changes will be overwritten. Changes should be made in the source code at https://github.com/firebase/firebase-js-sdk {% endcomment %}

GtagConfigParams interface

A set of common Google Analytics config settings recognized by gtag.js<!-- -->.

<b>Signature:</b>

typescript
export interface GtagConfigParams 

Properties

PropertyTypeDescription
allow_ad_personalization_signalsbooleanIf set to false, disables all advertising personalization with <code>gtag.js</code>. See Disable advertising features
allow_google_signalsbooleanIf set to false, disables all advertising features with <code>gtag.js</code>. See Disable advertising features
cookie_domainstringDefaults to <code>auto</code>. See Cookies and user identification
cookie_expiresnumberDefaults to 63072000 (two years, in seconds). See Cookies and user identification
cookie_flagsstringAppends additional flags to the cookie when set. See Cookies and user identification
cookie_prefixstringDefaults to <code>_ga</code>. See Cookies and user identification
cookie_updatebooleanIf set to true, will update cookies on each page load. Defaults to true. See Cookies and user identification
page_locationstringThe URL of the page. See Page views
page_titlestringThe title of the page. See Page views
send_page_viewbooleanWhether or not a page view should be sent. If set to true (default), a page view is automatically sent upon initialization of analytics. See Page views

GtagConfigParams.allow_ad_personalization_signals

If set to false, disables all advertising personalization with gtag.js<!-- -->. See Disable advertising features

<b>Signature:</b>

typescript
'allow_ad_personalization_signals'?: boolean;

GtagConfigParams.allow_google_signals

If set to false, disables all advertising features with gtag.js<!-- -->. See Disable advertising features

<b>Signature:</b>

typescript
'allow_google_signals'?: boolean;

Defaults to auto<!-- -->. See Cookies and user identification

<b>Signature:</b>

typescript
'cookie_domain'?: string;

Defaults to 63072000 (two years, in seconds). See Cookies and user identification

<b>Signature:</b>

typescript
'cookie_expires'?: number;

Appends additional flags to the cookie when set. See Cookies and user identification

<b>Signature:</b>

typescript
'cookie_flags'?: string;

Defaults to _ga<!-- -->. See Cookies and user identification

<b>Signature:</b>

typescript
'cookie_prefix'?: string;

If set to true, will update cookies on each page load. Defaults to true. See Cookies and user identification

<b>Signature:</b>

typescript
'cookie_update'?: boolean;

GtagConfigParams.page_location

The URL of the page. See Page views

<b>Signature:</b>

typescript
'page_location'?: string;

GtagConfigParams.page_title

The title of the page. See Page views

<b>Signature:</b>

typescript
'page_title'?: string;

GtagConfigParams.send_page_view

Whether or not a page view should be sent. If set to true (default), a page view is automatically sent upon initialization of analytics. See Page views

<b>Signature:</b>

typescript
'send_page_view'?: boolean;