Skip to content

Commit 711180c

Browse files
authored
chore(release): pulling release/3.6.0 into main (#1690)
2 parents 4fa8cbb + d19c0c0 commit 711180c

File tree

26 files changed

+117
-79
lines changed

26 files changed

+117
-79
lines changed

.eslintrc.json

+8-5
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
},
66
"lintAllEsApis": true,
77
"polyfills": [
8-
"Promise",
98
"URL",
109
"URLSearchParams",
10+
"Promise",
1111
"Number.isNaN",
1212
"Number.isInteger",
1313
"Array.from",
@@ -16,15 +16,18 @@
1616
"String.prototype.endsWith",
1717
"String.prototype.startsWith",
1818
"String.prototype.includes",
19+
"String.prototype.replaceAll",
20+
"String.fromCodePoint",
1921
"Object.entries",
2022
"Object.values",
21-
"Element.prototype.dataset",
22-
"String.prototype.replaceAll",
23+
"Object.assign",
2324
"TextEncoder",
2425
"TextDecoder",
25-
"String.fromCodePoint",
26+
"CustomEvent",
2627
"requestAnimationFrame",
27-
"cancelAnimationFrame"
28+
"cancelAnimationFrame",
29+
"navigator.sendBeacon",
30+
"Uint8Array"
2831
]
2932
},
3033
"env": {

.github/ISSUE_TEMPLATE/bug_report.md

+11-7
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Bug report
33
about: Create a report to help us improve
44
title: 'BUG : <Title>'
55
labels: bug, open source
6-
assignees: MoumitaM
6+
assignees: rudderlabs/js-sdk
77
---
88

99
**Describe the bug**
@@ -25,13 +25,17 @@ If applicable, add screenshots to help explain your problem.
2525

2626
**Additional Information (please complete the following information):**
2727

28-
- SDK installation: NPM/CDN
29-
- CDN URL: (if applicable)
30-
- NPM Version: (if applicable)
28+
- SDK installation type: NPM/CDN
29+
- SDK CDN URL: (if applicable)
30+
- SDK version: (for NPM installation)
31+
- Node version: (if applicable)
32+
- NPM version: (if applicable)
33+
- TypeScript version: (if applicable)
3134
- Webpage URL: (where the SDK is installed, if applicable)
32-
- Share the event payload
33-
- Integration that has the issue (if applicable)
34-
- Used JS Framework (e.g: NextJS, ReactJs, Vue) (if applicable)
35+
- Share the event payload: (if applicable)
36+
- Integration that has the issue: (if applicable)
37+
- Framework and version(e.g: Next.js, React, Vue): (if applicable)
38+
- Bundling toolset (e.g: Webpack, Rollup): (if applicable)
3539

3640
**Desktop (please complete the following information):**
3741

.github/ISSUE_TEMPLATE/feature_request.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Feature request
33
about: Suggest an idea for this project
44
title: 'Feature Request: <Title>'
55
labels: open source
6-
assignees: saikumarrs
6+
assignees: rudderlabs/js-sdk
77
---
88

99
**Is your feature request related to a problem? Please describe.**

package-lock.json

+6-6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@rudderstack/analytics-js-monorepo",
3-
"version": "3.5.0",
3+
"version": "3.6.0",
44
"private": true,
55
"description": "Monorepo for RudderStack Analytics JS SDK",
66
"workspaces": [

packages/analytics-js-integrations/CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@
22

33
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
44

5+
## [3.0.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-04-12)
6+
7+
8+
### Bug Fixes
9+
10+
* making the error message as warn ([#1686](https://github.com/rudderlabs/rudder-sdk-js/issues/1686)) ([56e34be](https://github.com/rudderlabs/rudder-sdk-js/commit/56e34be3575f66531bfe4910ff4aa970ed2ee208))
11+
512
## [3.0.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-04-02)
613

714

Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
## [3.0.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].2...@rudderstack/[email protected].3) (2024-04-02)
1+
## [3.0.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].3...@rudderstack/[email protected].4) (2024-04-12)
22

33

44
### Bug Fixes
55

6-
* ninetailed: modify page support ([#1677](https://github.com/rudderlabs/rudder-sdk-js/issues/1677)) ([e45ef06](https://github.com/rudderlabs/rudder-sdk-js/commit/e45ef06186cb4dc1d0568f2b39d8e786d278390a))
7-
* updated isLoaded and isReady conditions for mixpanel ([#1650](https://github.com/rudderlabs/rudder-sdk-js/issues/1650)) ([80c76a1](https://github.com/rudderlabs/rudder-sdk-js/commit/80c76a1f7f27a93930a6146730ac94d945b19b25))
6+
* making the error message as warn ([#1686](https://github.com/rudderlabs/rudder-sdk-js/issues/1686)) ([56e34be](https://github.com/rudderlabs/rudder-sdk-js/commit/56e34be3575f66531bfe4910ff4aa970ed2ee208))
87

packages/analytics-js-integrations/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@rudderstack/analytics-js-integrations",
3-
"version": "3.0.3",
3+
"version": "3.0.4",
44
"private": true,
55
"description": "RudderStack JavaScript SDK device mode integrations",
66
"main": "dist/npm/modern/cjs/index.js",

packages/analytics-js-integrations/project.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,9 @@
9494
"github": {
9595
"executor": "@jscutlery/semver:github",
9696
"options": {
97-
"tag": "@rudderstack/[email protected].3",
98-
"title": "@rudderstack/[email protected].3",
99-
"discussion-category": "@rudderstack/[email protected].3",
97+
"tag": "@rudderstack/[email protected].4",
98+
"title": "@rudderstack/[email protected].4",
99+
"discussion-category": "@rudderstack/[email protected].4",
100100
"notesFile": "./packages/analytics-js-integrations/CHANGELOG_LATEST.md"
101101
}
102102
}

packages/analytics-js-integrations/src/integrations/LinkedInInsightTag/browser.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ class LinkedInInsightTag {
6464
false,
6565
);
6666
if (!eventMapping[trimmedEvent]) {
67-
logger.error(
67+
logger.warn(
6868
`The "${event}" event is not mapped in the destination dashboard. It'll be skipped`,
6969
);
7070
return;

packages/analytics-js/CHANGELOG.md

+8
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22

33
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
44

5+
## [3.0.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-04-12)
6+
7+
8+
### Bug Fixes
9+
10+
* remove MutationObserver and make polyfill checks consistent ([#1688](https://github.com/rudderlabs/rudder-sdk-js/issues/1688)) ([51b42fe](https://github.com/rudderlabs/rudder-sdk-js/commit/51b42fe51a5fbfa79df23b9b36095cc494dbcaa1))
11+
* remove unnecessary window globals declarations ([#1687](https://github.com/rudderlabs/rudder-sdk-js/issues/1687)) ([09e5ab8](https://github.com/rudderlabs/rudder-sdk-js/commit/09e5ab89965a0b0dc5070891288a08358c103c0e))
12+
513
## [3.0.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-03-22)
614

715
### Dependency Updates
+6-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1-
## [3.0.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].2...@rudderstack/[email protected].3) (2024-03-22)
1+
## [3.0.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].3...@rudderstack/[email protected].4) (2024-04-12)
22

3-
### Dependency Updates
43

5-
* `@rudderstack/analytics-js-plugins` updated to version `3.0.2`
4+
### Bug Fixes
5+
6+
* remove MutationObserver and make polyfill checks consistent ([#1688](https://github.com/rudderlabs/rudder-sdk-js/issues/1688)) ([51b42fe](https://github.com/rudderlabs/rudder-sdk-js/commit/51b42fe51a5fbfa79df23b9b36095cc494dbcaa1))
7+
* remove unnecessary window globals declarations ([#1687](https://github.com/rudderlabs/rudder-sdk-js/issues/1687)) ([09e5ab8](https://github.com/rudderlabs/rudder-sdk-js/commit/09e5ab89965a0b0dc5070891288a08358c103c0e))
8+

packages/analytics-js/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@rudderstack/analytics-js",
3-
"version": "3.0.3",
3+
"version": "3.0.4",
44
"description": "RudderStack JavaScript SDK",
55
"main": "dist/npm/modern/cjs/index.js",
66
"module": "dist/npm/modern/esm/index.js",

packages/analytics-js/project.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -126,9 +126,9 @@
126126
"github": {
127127
"executor": "@jscutlery/semver:github",
128128
"options": {
129-
"tag": "@rudderstack/[email protected].3",
130-
"title": "@rudderstack/[email protected].3",
131-
"discussion-category": "@rudderstack/[email protected].3",
129+
"tag": "@rudderstack/[email protected].4",
130+
"title": "@rudderstack/[email protected].4",
131+
"discussion-category": "@rudderstack/[email protected].4",
132132
"notesFile": "./packages/analytics-js/CHANGELOG_LATEST.md"
133133
}
134134
}

packages/analytics-js/src/components/capabilitiesManager/detection/dom.ts

+25-22
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,39 @@
1-
import { isFunction, isUndefined } from '@rudderstack/analytics-js-common/utilities/checks';
1+
import { isFunction } from '@rudderstack/analytics-js-common/utilities/checks';
22

33
const isDatasetAvailable = (): boolean => {
4-
const testElement = document.createElement('div');
4+
const testElement = globalThis.document.createElement('div');
55
testElement.setAttribute('data-a-b', 'c');
66
return testElement.dataset ? testElement.dataset.aB === 'c' : false;
77
};
88

99
const legacyJSEngineRequiredPolyfills: Record<string, () => boolean> = {
10-
URL: () => !isFunction(globalThis.URL) || !globalThis.URLSearchParams,
11-
MutationObserver: () => isUndefined(MutationObserver),
12-
Promise: () => isUndefined(Promise),
13-
'Number.isNaN': () => !Number.isNaN,
14-
'Number.isInteger': () => !Number.isInteger,
15-
'Array.from': () => !Array.from,
16-
'Array.prototype.find': () => !Array.prototype.find,
17-
'Array.prototype.includes': () => !Array.prototype.includes,
18-
'String.prototype.endsWith': () => !String.prototype.endsWith,
19-
'String.prototype.startsWith': () => !String.prototype.startsWith,
20-
'String.prototype.includes': () => !String.prototype.includes,
21-
'Object.entries': () => !Object.entries,
22-
'Object.values': () => !Object.values,
23-
'Object.assign': () => typeof Object.assign !== 'function',
10+
// Ideally, we should separate the checks for URL and URLSearchParams but
11+
// the polyfill service serves them under the same feature name, "URL".
12+
URL: () => !isFunction(globalThis.URL) || !isFunction(globalThis.URLSearchParams),
13+
Promise: () => !isFunction(globalThis.Promise),
14+
'Number.isNaN': () => !isFunction(globalThis.Number.isNaN),
15+
'Number.isInteger': () => !isFunction(globalThis.Number.isInteger),
16+
'Array.from': () => !isFunction(globalThis.Array.from),
17+
'Array.prototype.find': () => !isFunction(globalThis.Array.prototype.find),
18+
'Array.prototype.includes': () => !isFunction(globalThis.Array.prototype.includes),
19+
'String.prototype.endsWith': () => !isFunction(globalThis.String.prototype.endsWith),
20+
'String.prototype.startsWith': () => !isFunction(globalThis.String.prototype.startsWith),
21+
'String.prototype.includes': () => !isFunction(globalThis.String.prototype.includes),
22+
'String.prototype.replaceAll': () => !isFunction(globalThis.String.prototype.replaceAll),
23+
'String.fromCodePoint': () => !isFunction(globalThis.String.fromCodePoint),
24+
'Object.entries': () => !isFunction(globalThis.Object.entries),
25+
'Object.values': () => !isFunction(globalThis.Object.values),
26+
'Object.assign': () => !isFunction(globalThis.Object.assign),
2427
'Element.prototype.dataset': () => !isDatasetAvailable(),
25-
'String.prototype.replaceAll': () => !String.prototype.replaceAll,
26-
TextEncoder: () => isUndefined(TextEncoder) || isUndefined(TextDecoder),
27-
'String.fromCodePoint': () => !String.fromCodePoint,
28+
// Ideally, we should separate the checks for TextEncoder and TextDecoder but
29+
// the polyfill service serves them under the same feature name, "TextEncoder".
30+
TextEncoder: () => !isFunction(globalThis.TextEncoder) || !isFunction(globalThis.TextDecoder),
2831
requestAnimationFrame: () =>
2932
!isFunction(globalThis.requestAnimationFrame) || !isFunction(globalThis.cancelAnimationFrame),
3033
CustomEvent: () => !isFunction(globalThis.CustomEvent),
31-
/* eslint-disable-next-line */
32-
'navigator.sendBeacon': () => !isFunction(navigator.sendBeacon),
33-
ArrayBuffer: () => !isFunction(Uint8Array),
34+
'navigator.sendBeacon': () => !isFunction(globalThis.navigator.sendBeacon),
35+
// Note, the polyfill service serves both ArrayBuffer and Uint8Array under the same feature name, "ArrayBuffer".
36+
ArrayBuffer: () => !isFunction(globalThis.Uint8Array),
3437
};
3538

3639
const isLegacyJSEngine = (): boolean => {

packages/analytics-js/src/index.ts

-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import type { RudderAnalytics } from './app/RudderAnalytics';
22
import type { RudderAnalyticsPreloader } from './components/preloadBuffer/types';
3-
import type { IRudderStackGlobals } from './app/IRudderStackGlobals';
43

54
export {
65
type AnonymousIdOptions,
@@ -21,7 +20,6 @@ export { type LogLevel } from '@rudderstack/analytics-js-common/types/Logger';
2120
export { type PluginName } from '@rudderstack/analytics-js-common/types/PluginsManager';
2221
export { type IdentifyTraits } from '@rudderstack/analytics-js-common/types/traits';
2322
export { RudderAnalytics } from './app/RudderAnalytics';
24-
export { type IRudderStackGlobals } from './app/IRudderStackGlobals';
2523
export {
2624
type RudderAnalyticsPreloader,
2725
type PreloadedEventCall,
@@ -30,8 +28,5 @@ export {
3028
declare global {
3129
interface Window {
3230
rudderanalytics: RudderAnalytics | RudderAnalyticsPreloader | undefined;
33-
RudderStackGlobals: IRudderStackGlobals;
34-
rudderAnalyticsMount: () => void;
35-
rudderAnalyticsBuildType: 'legacy' | 'modern';
3631
}
3732
}

packages/analytics-js/src/types/rudderanalytics.d.ts

-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ declare global {
99
interface Window {
1010
rudderanalytics: RudderAnalytics | RudderAnalyticsPreloader | undefined;
1111
RudderStackGlobals: IRudderStackGlobals;
12-
rudderAnalyticsMount: () => void;
13-
rudderAnalyticsBuildType: 'legacy' | 'modern';
1412
RudderSnippetVersion?: string;
1513
}
1614
}

packages/loading-scripts/CHANGELOG.md

+10
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,16 @@
22

33
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
44

5+
## [3.0.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-04-12)
6+
7+
### Dependency Updates
8+
9+
* `@rudderstack/analytics-js` updated to version `3.0.3`
10+
11+
### Bug Fixes
12+
13+
* remove unnecessary window globals declarations ([#1687](https://github.com/rudderlabs/rudder-sdk-js/issues/1687)) ([09e5ab8](https://github.com/rudderlabs/rudder-sdk-js/commit/09e5ab89965a0b0dc5070891288a08358c103c0e))
14+
515
## [3.0.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected]...@rudderstack/[email protected]) (2024-03-22)
616

717
### Dependency Updates
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
## [3.0.3](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].2...@rudderstack/[email protected].3) (2024-03-22)
1+
## [3.0.4](https://github.com/rudderlabs/rudder-sdk-js/compare/@rudderstack/[email protected].3...@rudderstack/[email protected].4) (2024-04-12)
22

33
### Dependency Updates
44

5-
* `@rudderstack/analytics-js` updated to version `3.0.2`
5+
* `@rudderstack/analytics-js` updated to version `3.0.3`
6+
7+
### Bug Fixes
8+
9+
* remove unnecessary window globals declarations ([#1687](https://github.com/rudderlabs/rudder-sdk-js/issues/1687)) ([09e5ab8](https://github.com/rudderlabs/rudder-sdk-js/commit/09e5ab89965a0b0dc5070891288a08358c103c0e))
10+

packages/loading-scripts/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@rudderstack/analytics-js-loading-scripts",
3-
"version": "3.0.3",
3+
"version": "3.0.4",
44
"private": true,
55
"description": "Loading script for RudderStack JavaScript SDK",
66
"main": "./src/index.js",

packages/loading-scripts/project.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,9 @@
8989
"github": {
9090
"executor": "@jscutlery/semver:github",
9191
"options": {
92-
"tag": "@rudderstack/[email protected].3",
93-
"title": "@rudderstack/[email protected].3",
94-
"discussion-category": "@rudderstack/[email protected].3",
92+
"tag": "@rudderstack/[email protected].4",
93+
"title": "@rudderstack/[email protected].4",
94+
"discussion-category": "@rudderstack/[email protected].4",
9595
"notesFile": "./packages/loading-scripts/CHANGELOG_LATEST.md"
9696
}
9797
}

packages/loading-scripts/src/types/rudderanalytics.d.ts

-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import type {
2-
IRudderStackGlobals,
32
RudderAnalytics,
43
PreloadedEventCall,
54
RudderAnalyticsPreloader,
@@ -8,7 +7,6 @@ import type {
87
declare global {
98
interface Window {
109
rudderanalytics: RudderAnalytics | RudderAnalyticsPreloader | undefined;
11-
RudderStackGlobals: IRudderStackGlobals;
1210
rudderAnalyticsMount: () => void;
1311
rudderAnalyticsBuildType: 'legacy' | 'modern';
1412
RudderSnippetVersion?: string;

0 commit comments

Comments
 (0)