-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(release): pull hotfix-release/3.27.0 into main (#1807)
- Loading branch information
Showing
47 changed files
with
246 additions
and
83 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,13 @@ | |
|
||
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). | ||
|
||
## [3.8.0](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-07-24) | ||
|
||
|
||
### Features | ||
|
||
* **analytics-js-integrations:** onboard ga4 v2 hybrid mode ([#1802](https://github.com/rudderlabs/rudder-sdk-js/issues/1802)) ([2c8c3be](https://github.com/rudderlabs/rudder-sdk-js/commit/2c8c3bea8ada300c62729eb114dbe8ff84ae9269)) | ||
|
||
## [3.7.0](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-07-19) | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
## [3.7.0](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/analytics-js-common@3.6.1...@rudderstack/analytics-js-common@3.7.0) (2024-07-19) | ||
## [3.8.0](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/analytics-js-common@3.7.0...@rudderstack/analytics-js-common@3.8.0) (2024-07-24) | ||
|
||
|
||
### Features | ||
|
||
* error reporting plugin ([#1601](https://github.com/rudderlabs/rudder-sdk-js/issues/1601)) ([1f2629e](https://github.com/rudderlabs/rudder-sdk-js/commit/1f2629e594740763ce9bd54a21213b92d80ae085)) | ||
|
||
|
||
### Bug Fixes | ||
|
||
* event API overloads ([#1782](https://github.com/rudderlabs/rudder-sdk-js/issues/1782)) ([02c5b47](https://github.com/rudderlabs/rudder-sdk-js/commit/02c5b47d0a83250fb5180e9ed467a92361663dab)) | ||
* **analytics-js-integrations:** onboard ga4 v2 hybrid mode ([#1802](https://github.com/rudderlabs/rudder-sdk-js/issues/1802)) ([2c8c3be](https://github.com/rudderlabs/rudder-sdk-js/commit/2c8c3bea8ada300c62729eb114dbe8ff84ae9269)) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
packages/analytics-js-common/src/constants/integrations/GA4_V2/constants.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
const DIR_NAME = 'GA4_V2'; | ||
const NAME = 'GA4_V2'; | ||
const DISPLAY_NAME = 'Google Analytics 4 (GA4) V2'; | ||
|
||
const DISPLAY_NAME_TO_DIR_NAME_MAP = { [DISPLAY_NAME]: DIR_NAME }; | ||
const CNameMapping = { | ||
[NAME]: NAME, | ||
'Google Analytics 4 V2': NAME, | ||
'Google analytics 4 V2': NAME, | ||
'google analytics 4 V2': NAME, | ||
'Google Analytics4 V2': NAME, | ||
'Google analytics4 V2': NAME, | ||
'google analytics4 V2': NAME, | ||
'Google Analytics 4 (GA4) V2': NAME, | ||
'google analytics 4 (ga4) V2': NAME, | ||
GoogleAnalytics4V2: NAME, | ||
}; | ||
|
||
export { NAME, CNameMapping, DISPLAY_NAME_TO_DIR_NAME_MAP, DISPLAY_NAME, DIR_NAME }; | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,11 @@ | |
|
||
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). | ||
|
||
## [0.3.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-07-24) | ||
|
||
### Dependency Updates | ||
|
||
* `@rudderstack/analytics-js-common` updated to version `0.3.3` | ||
## [0.3.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-07-19) | ||
|
||
### Dependency Updates | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,5 @@ | ||
## [0.3.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].2...@rudderstack/[email protected].3) (2024-07-19) | ||
## [0.3.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].3...@rudderstack/[email protected].4) (2024-07-24) | ||
|
||
### Dependency Updates | ||
|
||
* `@rudderstack/analytics-js-common` updated to version `0.3.2` | ||
|
||
### Bug Fixes | ||
|
||
* event API overloads ([#1782](https://github.com/rudderlabs/rudder-sdk-js/issues/1782)) ([02c5b47](https://github.com/rudderlabs/rudder-sdk-js/commit/02c5b47d0a83250fb5180e9ed467a92361663dab)) | ||
|
||
* `@rudderstack/analytics-js-common` updated to version `0.3.3` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -52,9 +52,9 @@ | |
"github": { | ||
"executor": "@jscutlery/semver:github", | ||
"options": { | ||
"tag": "@rudderstack/[email protected].3", | ||
"title": "@rudderstack/[email protected].3", | ||
"discussion-category": "@rudderstack/[email protected].3", | ||
"tag": "@rudderstack/[email protected].4", | ||
"title": "@rudderstack/[email protected].4", | ||
"discussion-category": "@rudderstack/[email protected].4", | ||
"notesFile": "./packages/analytics-js-cookies/CHANGELOG_LATEST.md" | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,16 @@ | |
|
||
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). | ||
|
||
## [3.5.0](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-07-24) | ||
|
||
### Dependency Updates | ||
|
||
* `@rudderstack/analytics-js-common` updated to version `3.4.5` | ||
|
||
### Features | ||
|
||
* **analytics-js-integrations:** onboard ga4 v2 hybrid mode ([#1802](https://github.com/rudderlabs/rudder-sdk-js/issues/1802)) ([2c8c3be](https://github.com/rudderlabs/rudder-sdk-js/commit/2c8c3bea8ada300c62729eb114dbe8ff84ae9269)) | ||
|
||
## [3.4.5](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-07-19) | ||
|
||
### Dependency Updates | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
## [3.4.5](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].4...@rudderstack/analytics-js-integrations@3.4.5) (2024-07-19) | ||
## [3.5.0](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].5...@rudderstack/analytics-js-integrations@3.5.0) (2024-07-24) | ||
|
||
### Dependency Updates | ||
|
||
* `@rudderstack/analytics-js-common` updated to version `3.4.4` | ||
* `@rudderstack/analytics-js-common` updated to version `3.4.5` | ||
|
||
### Bug Fixes | ||
### Features | ||
|
||
* event API overloads ([#1782](https://github.com/rudderlabs/rudder-sdk-js/issues/1782)) ([02c5b47](https://github.com/rudderlabs/rudder-sdk-js/commit/02c5b47d0a83250fb5180e9ed467a92361663dab)) | ||
* **analytics-js-integrations:** onboard ga4 v2 hybrid mode ([#1802](https://github.com/rudderlabs/rudder-sdk-js/issues/1802)) ([2c8c3be](https://github.com/rudderlabs/rudder-sdk-js/commit/2c8c3bea8ada300c62729eb114dbe8ff84ae9269)) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
87 changes: 87 additions & 0 deletions
87
packages/analytics-js-integrations/src/integrations/GA4_V2/browser.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
import { | ||
NAME, | ||
DISPLAY_NAME, | ||
} from '@rudderstack/analytics-js-common/constants/integrations/GA4_V2/constants'; | ||
import { isDefinedAndNotNull } from '../../utils/commonUtils'; | ||
import Logger from '../../utils/logger'; | ||
import { GA4 } from '../GA4'; | ||
|
||
const logger = new Logger(DISPLAY_NAME); | ||
|
||
// eslint-disable-next-line @typescript-eslint/naming-convention | ||
export default class GA4_V2 extends GA4 { | ||
constructor(config, analytics, destinationInfo) { | ||
if (analytics.logLevel) { | ||
logger.setLogLevel(analytics.logLevel); | ||
} | ||
|
||
const newConfig = { ...config }; | ||
/** | ||
* Sample configData | ||
* "{\"ACCOUNT\":\"321500532\",\"PROPERTY\":\"449999397\",\"DATA_STREAM\":{\"value\":\"G-Q3C88MMDW1\",\"type\":\"gtag\"},\"MEASUREMENT_PROTOCOL_SECRET\":\"sample_secret\"}"; | ||
*/ | ||
|
||
if (isDefinedAndNotNull(config.configData)) { | ||
const configDetails = JSON.parse(config.configData); | ||
newConfig.propertyId = configDetails.PROPERTY; | ||
newConfig.typesOfClient = configDetails.DATA_STREAM.type; | ||
if (newConfig.typesOfClient !== 'gtag') { | ||
logger.error('Invalid typesOfClient. Please select gtag'); | ||
} | ||
newConfig.measurementId = configDetails.DATA_STREAM.value; | ||
} | ||
|
||
if (!isDefinedAndNotNull(newConfig.measurementId)) { | ||
logger.error('Measurement ID is required for GA4'); | ||
} | ||
|
||
newConfig.isExtendedGa4_V2 = true; | ||
super(newConfig, analytics, destinationInfo); | ||
this.analytics = analytics; | ||
this.name = NAME; | ||
({ | ||
shouldApplyDeviceModeTransformation: this.shouldApplyDeviceModeTransformation, | ||
propagateEventsUntransformedOnError: this.propagateEventsUntransformedOnError, | ||
destinationId: this.destinationId, | ||
} = destinationInfo ?? {}); | ||
} | ||
|
||
init() { | ||
return super.init(); | ||
} | ||
|
||
isLoaded() { | ||
return super.isLoaded(); | ||
} | ||
|
||
isReady() { | ||
return super.isReady(); | ||
} | ||
|
||
identify(rudderElement) { | ||
return super.identify(rudderElement); | ||
} | ||
|
||
track(rudderElement) { | ||
return super.track(rudderElement); | ||
} | ||
|
||
page(rudderElement) { | ||
return super.page(rudderElement); | ||
} | ||
|
||
group(rudderElement) { | ||
return super.group(rudderElement); | ||
} | ||
|
||
getDataForIntegrationsObject() { | ||
const { clientId, sessionId, sessionNumber } = super.getClientDetails(); | ||
return { | ||
[DISPLAY_NAME]: { | ||
clientId, | ||
sessionId, | ||
sessionNumber, | ||
}, | ||
}; | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
packages/analytics-js-integrations/src/integrations/GA4_V2/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default as GA4_V2 } from './browser'; |
Oops, something went wrong.