react-marketing-tools 0.4.3 → 1.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/analytics/analyticsEventService.d.ts +13 -0
- package/dist/analytics/ga4GoogleAnalyticsEventTracking.d.ts +3 -0
- package/dist/analytics/handleDataLayerPush.d.ts +3 -0
- package/dist/analytics/helpers.d.ts +41 -0
- package/dist/buildConfig/index.d.ts +8 -0
- package/dist/core/createAnalytics.d.ts +6 -0
- package/dist/core/types.d.ts +39 -0
- package/dist/core.d.ts +2 -0
- package/dist/core.js +59 -0
- package/dist/destinations/gtm.d.ts +6 -0
- package/dist/index.d.ts +6 -6
- package/dist/index.js +32773 -0
- package/dist/ipInfo/index.d.ts +3 -0
- package/dist/utilities/assertValueCheckers.d.ts +1 -0
- package/dist/utilities/commonFunctions.d.ts +5 -0
- package/dist/utilities/cookies.d.ts +1 -0
- package/package.json +51 -46
- package/dist/react-marketing-tools.es.js +0 -47979
- package/dist/react-marketing-tools.umd.js +0 -27
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { IpInfo, ServerLocationData } from '../types';
|
|
2
|
+
export declare const buildServerLocationData: (withServerLocationInfo: boolean | undefined, IP_INFO_TOKEN: string | undefined) => Promise<ServerLocationData | undefined>;
|
|
3
|
+
export declare const getIpInfo: (IP_INFO_TOKEN: string) => Promise<IpInfo>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const assertIsTrue: (condition: boolean, errorMessage?: string) => void;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const isClientSide: () => boolean;
|
|
2
|
+
export declare const objectHasAttributes: (obj: object, key?: string) => boolean;
|
|
3
|
+
export declare const replaceWhiteSpace: (stringValue: string, replaceValue: string) => string;
|
|
4
|
+
export declare const checkAllArrayValuesReturnTrue: (valueArray: boolean[]) => boolean;
|
|
5
|
+
export declare const hashString: (value: string) => Promise<string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const getCookieValueByName: (name: string) => string | undefined;
|
package/package.json
CHANGED
|
@@ -1,25 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-marketing-tools",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "1.0.0-alpha.0",
|
|
5
5
|
"description": "React Marketing Tools are a set of tools to make it easier for you to implement analytics and track user journeys, interactions throughout your App. using dataLayer/Google Tag Manager, GA4 fetch directly or coming soon facebook pixel.",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "bronz3beard <exempli.gratia.webdesign@gmail.com> (https://www.heyrory.com/)",
|
|
8
8
|
"homepage": "https://www.heyrory.com/",
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
11
|
-
"url": "https://github.com/bronz3beard/react-marketing-tools"
|
|
11
|
+
"url": "git+https://github.com/bronz3beard/react-marketing-tools.git"
|
|
12
12
|
},
|
|
13
13
|
"bugs": {
|
|
14
14
|
"url": "https://github.com/bronz3beard/react-marketing-tools/issues"
|
|
15
15
|
},
|
|
16
16
|
"files": [
|
|
17
|
-
"
|
|
18
|
-
"./dist/types/index.d.ts",
|
|
19
|
-
"./dist/manifest.json",
|
|
20
|
-
"./dist/react-marketing-tools.es.js",
|
|
21
|
-
"./dist/react-marketing-tools.umd.js",
|
|
22
|
-
"./README.md"
|
|
17
|
+
"dist"
|
|
23
18
|
],
|
|
24
19
|
"keywords": [
|
|
25
20
|
"javascript",
|
|
@@ -34,23 +29,39 @@
|
|
|
34
29
|
"pixel",
|
|
35
30
|
"dataLayer"
|
|
36
31
|
],
|
|
37
|
-
"main": "./dist/
|
|
38
|
-
"module": "./dist/react-marketing-tools.es.js",
|
|
32
|
+
"main": "./dist/index.js",
|
|
39
33
|
"types": "./dist/index.d.ts",
|
|
40
34
|
"exports": {
|
|
41
35
|
".": {
|
|
42
36
|
"types": "./dist/index.d.ts",
|
|
43
|
-
"
|
|
44
|
-
|
|
45
|
-
|
|
37
|
+
"default": "./dist/index.js"
|
|
38
|
+
},
|
|
39
|
+
"./core": {
|
|
40
|
+
"types": "./dist/core.d.ts",
|
|
41
|
+
"default": "./dist/core.js"
|
|
42
|
+
},
|
|
43
|
+
"./package.json": "./package.json"
|
|
44
|
+
},
|
|
45
|
+
"sideEffects": false,
|
|
46
|
+
"engines": {
|
|
47
|
+
"node": ">=22.12"
|
|
48
|
+
},
|
|
49
|
+
"publishConfig": {
|
|
50
|
+
"tag": "next"
|
|
46
51
|
},
|
|
47
52
|
"scripts": {
|
|
48
|
-
"
|
|
49
|
-
"build": "
|
|
50
|
-
"
|
|
51
|
-
"
|
|
53
|
+
"build": "vite build && tsc -p tsconfig.build.json",
|
|
54
|
+
"build:watch": "vite build --watch",
|
|
55
|
+
"check:package": "publint --strict && attw --pack . --profile esm-only",
|
|
56
|
+
"check:size": "node scripts/check-size.mjs",
|
|
57
|
+
"format": "prettier --write .",
|
|
58
|
+
"format:check": "prettier --check .",
|
|
59
|
+
"lint": "eslint .",
|
|
52
60
|
"mock:publish": "npm pack --dry-run",
|
|
53
|
-
"
|
|
61
|
+
"prepublishOnly": "npm run build && npm run check:size",
|
|
62
|
+
"test": "vitest run",
|
|
63
|
+
"test:watch": "vitest",
|
|
64
|
+
"typecheck": "tsc --noEmit"
|
|
54
65
|
},
|
|
55
66
|
"browserslist": {
|
|
56
67
|
"production": [
|
|
@@ -64,36 +75,30 @@
|
|
|
64
75
|
"last 1 safari version"
|
|
65
76
|
]
|
|
66
77
|
},
|
|
67
|
-
"eslintConfig": {
|
|
68
|
-
"env": {
|
|
69
|
-
"browser": true,
|
|
70
|
-
"node": true,
|
|
71
|
-
"es2020": true
|
|
72
|
-
},
|
|
73
|
-
"extends": [
|
|
74
|
-
"eslint:recommended",
|
|
75
|
-
"plugin:react/recommended"
|
|
76
|
-
],
|
|
77
|
-
"parserOptions": {
|
|
78
|
-
"sourceType": "module"
|
|
79
|
-
}
|
|
80
|
-
},
|
|
81
78
|
"dependencies": {
|
|
82
|
-
"device-detector-js": "^3.0.3"
|
|
83
|
-
|
|
79
|
+
"device-detector-js": "^3.0.3"
|
|
80
|
+
},
|
|
81
|
+
"peerDependencies": {
|
|
82
|
+
"react": ">=17.0.0"
|
|
84
83
|
},
|
|
85
84
|
"devDependencies": {
|
|
86
|
-
"@
|
|
87
|
-
"@types/
|
|
88
|
-
"@types/react
|
|
89
|
-
"@
|
|
90
|
-
"
|
|
91
|
-
"eslint
|
|
92
|
-
"
|
|
93
|
-
"
|
|
94
|
-
"react-
|
|
95
|
-
"
|
|
96
|
-
"
|
|
97
|
-
"
|
|
85
|
+
"@arethetypeswrong/cli": "^0.18.5",
|
|
86
|
+
"@types/node": "^22.20.4",
|
|
87
|
+
"@types/react": "^19.3.0",
|
|
88
|
+
"@types/react-dom": "^19.3.0",
|
|
89
|
+
"@typescript/native": "npm:typescript@^7.0.2",
|
|
90
|
+
"@eslint/js": "^10.0.1",
|
|
91
|
+
"eslint": "^10.11.0",
|
|
92
|
+
"eslint-config-prettier": "^10.1.8",
|
|
93
|
+
"eslint-plugin-react-hooks": "^7.1.1",
|
|
94
|
+
"jsdom": "^30.1.0",
|
|
95
|
+
"prettier": "^3.9.8",
|
|
96
|
+
"publint": "^0.3.24",
|
|
97
|
+
"react": "^19.3.0",
|
|
98
|
+
"react-dom": "^19.3.0",
|
|
99
|
+
"typescript": "npm:@typescript/typescript6@^6.0.2",
|
|
100
|
+
"typescript-eslint": "^8.70.0",
|
|
101
|
+
"vite": "^8.3.0",
|
|
102
|
+
"vitest": "^5.0.1"
|
|
98
103
|
}
|
|
99
104
|
}
|