countly-sdk-web 22.2.2 → 22.2.3

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.
Files changed (91) hide show
  1. package/.eslintignore +17 -17
  2. package/.eslintrc.js +215 -215
  3. package/.github/dependabot.yml +20 -20
  4. package/.github/workflows/codeql-analysis.yml +71 -71
  5. package/.github/workflows/documentation.yml +24 -0
  6. package/.github/workflows/node.js.yml +25 -41
  7. package/CHANGELOG.md +241 -237
  8. package/LICENSE +19 -19
  9. package/README.md +86 -122
  10. package/SECURITY.md +3 -3
  11. package/bower.json +29 -29
  12. package/cypress/.eslintrc.js +22 -22
  13. package/cypress/fixtures/base.html +8 -0
  14. package/cypress/fixtures/scroll_test.html +60 -0
  15. package/cypress/fixtures/scroll_test_2.html +48 -0
  16. package/cypress/fixtures/scroll_test_3.html +72 -0
  17. package/cypress/fixtures/session_test_auto.html +51 -0
  18. package/cypress/fixtures/session_test_manual_1.html +58 -0
  19. package/cypress/fixtures/session_test_manual_2.html +54 -0
  20. package/cypress/fixtures/user_agent.html +20 -0
  21. package/cypress/integration/consents.js +165 -165
  22. package/cypress/integration/device_id.js +1085 -830
  23. package/cypress/integration/events.js +65 -65
  24. package/cypress/integration/heatmaps.js +52 -0
  25. package/cypress/integration/internal_limits.js +153 -153
  26. package/cypress/integration/reponse_validation.js +170 -170
  27. package/cypress/integration/sessions.js +196 -60
  28. package/cypress/integration/user_agent.js +63 -0
  29. package/cypress/integration/user_details.js +40 -40
  30. package/cypress/integration/utm.js +236 -236
  31. package/cypress/integration/views.js +62 -62
  32. package/cypress/plugins/index.js +22 -22
  33. package/cypress/support/commands.js +322 -298
  34. package/cypress/support/helper.js +59 -59
  35. package/cypress/support/index.js +2 -2
  36. package/cypress/support/integration_helper.js +17 -0
  37. package/cypress.json +3 -1
  38. package/examples/example_apm.html +51 -51
  39. package/examples/example_fb.html +50 -50
  40. package/examples/example_formdata.html +47 -47
  41. package/examples/example_ga_adapter.html +173 -173
  42. package/examples/example_gdpr.html +82 -82
  43. package/examples/example_internal_limits.html +184 -184
  44. package/examples/example_multiple_instances.html +52 -52
  45. package/examples/example_rating_widgets.html +80 -80
  46. package/examples/example_remote_config.html +38 -38
  47. package/examples/example_sync.html +36 -36
  48. package/examples/examples_feedback_widgets.html +81 -81
  49. package/examples/mpa/boomerang/boomerang-1.0.0.js +22871 -22871
  50. package/examples/mpa/boomerang/countly_boomerang.js +138 -138
  51. package/examples/mpa/index.html +816 -816
  52. package/examples/react/README.md +35 -35
  53. package/examples/react/package.json +37 -37
  54. package/examples/react/public/index.html +19 -19
  55. package/examples/react/public/manifest.json +25 -25
  56. package/examples/react/public/robots.txt +3 -3
  57. package/examples/react/src/App-WithEffect.js +33 -33
  58. package/examples/react/src/App-WithRouter.js +46 -46
  59. package/examples/react/src/App.test.js +9 -9
  60. package/examples/react/src/Components/Contact.js +28 -28
  61. package/examples/react/src/Components/Header.js +88 -88
  62. package/examples/react/src/Components/Home.js +23 -23
  63. package/examples/react/src/Components/Users.js +43 -43
  64. package/examples/react/src/Components/styles.css +25 -25
  65. package/examples/react/src/ErrorBoundary.js +28 -28
  66. package/examples/react/src/Location-WithEffect.js +27 -27
  67. package/examples/react/src/Location-WithRouter.js +23 -23
  68. package/examples/react/src/index.css +5 -5
  69. package/examples/react/src/index.js +68 -68
  70. package/examples/react/src/serviceWorker.js +141 -141
  71. package/examples/react/src/setupTests.js +5 -5
  72. package/examples/symbolication/.babelrc +11 -11
  73. package/examples/symbolication/.editorconfig +8 -8
  74. package/examples/symbolication/.yo-rc.json +53 -53
  75. package/examples/symbolication/README.md +33 -33
  76. package/examples/symbolication/package.json +22 -22
  77. package/examples/symbolication/src/index.js +47 -47
  78. package/examples/symbolication/static/index.html +21 -21
  79. package/examples/symbolication/webpack.config.js +27 -27
  80. package/generateDocs.sh +80 -79
  81. package/inch.json +6 -6
  82. package/jsdoc_conf.json +4 -2
  83. package/lib/countly.js +4625 -4416
  84. package/lib/countly.min.js +126 -117
  85. package/package.json +57 -57
  86. package/plugin/boomerang/boomerang.min.js +10 -10
  87. package/plugin/boomerang/countly_boomerang.js +150 -150
  88. package/plugin/ga_adapter/doc.md +73 -73
  89. package/plugin/ga_adapter/ga_adapter.js +451 -451
  90. package/webpack.config.js +12 -12
  91. package/countly-sdk-web-22.2.2.tgz +0 -0
package/.eslintignore CHANGED
@@ -1,18 +1,18 @@
1
- lib/countly.min.js
2
- lib/countly.pack.js
3
- plugin
4
- examples
5
- test
6
- node_modules
7
- coverage
8
- .vscode
9
- .github
10
- .gitignore
11
- bower.json
12
- CHANGELOG.md
13
- cypress.json
14
- generateDocs.sh
15
- inch.json
16
- jsdoc_conf.json
17
- LICENSE
1
+ lib/countly.min.js
2
+ lib/countly.pack.js
3
+ plugin
4
+ examples
5
+ test
6
+ node_modules
7
+ coverage
8
+ .vscode
9
+ .github
10
+ .gitignore
11
+ bower.json
12
+ CHANGELOG.md
13
+ cypress.json
14
+ generateDocs.sh
15
+ inch.json
16
+ jsdoc_conf.json
17
+ LICENSE
18
18
  webpack.config.js
package/.eslintrc.js CHANGED
@@ -1,215 +1,215 @@
1
- module.exports = {
2
- /**
3
- * By default, ESLint expects ECMAScript 5 syntax. You can override that setting to enable support
4
- * for other ECMAScript versions as well as JSX by using parser options. However for IE9 compatibility
5
- * updating it to ECMAScript 6 or above is currently not permitted. -D
6
- * */
7
- env: {
8
- browser: true,
9
- amd: true,
10
- commonjs: true
11
- },
12
- extends: "airbnb/legacy",
13
- rules: {
14
- "prefer-arrow-callback": "off",
15
- "prefer-destructuring": "off",
16
- "comma-dangle": "off",
17
- "no-restricted-globals": "off",
18
- "no-restricted-properties": "off",
19
- //
20
- "no-unused-vars": "warn",
21
- "no-var": "off",
22
- "func-names": "off",
23
- "consistent-return": "off",
24
- "prefer-rest-params": "off",
25
- radix: "off",
26
- "prefer-spread": "off",
27
- "no-plusplus": "off",
28
- camelcase: "off",
29
- "no-use-before-define": "off",
30
- "no-lonely-if": "off",
31
- "no-restricted-syntax": "off",
32
- "vars-on-top": "off",
33
- "no-param-reassign": "off",
34
- "max-len": "off",
35
- "guard-for-in": "off",
36
- "no-underscore-dangle": "off",
37
- "no-bitwise": "off",
38
- "no-mixed-operators": "off",
39
- "object-shorthand": "off",
40
- "block-spacing": [
41
- "error",
42
- "always"
43
- ],
44
- "brace-style": [
45
- "error",
46
- "stroustrup"
47
- ],
48
- "comma-spacing": [
49
- "error",
50
- {
51
- before: false,
52
- after: true
53
- }
54
- ],
55
- "comma-style": [
56
- "error",
57
- "last"
58
- ],
59
- "computed-property-spacing": [
60
- "error",
61
- "never"
62
- ],
63
- curly: [
64
- "error",
65
- "all"
66
- ],
67
- "eol-last": "off",
68
- "func-call-spacing": [
69
- "error",
70
- "never"
71
- ],
72
- indent: [
73
- "error",
74
- 4
75
- ],
76
- "key-spacing": [
77
- "error",
78
- {
79
- beforeColon: false,
80
- afterColon: true
81
- }
82
- ],
83
- "keyword-spacing": [
84
- "error",
85
- {
86
- before: true,
87
- after: true
88
- }
89
- ],
90
- "lines-between-class-members": [
91
- "error",
92
- "always"
93
- ],
94
- "no-multi-spaces": [
95
- "error"
96
- ],
97
- "no-trailing-spaces": [
98
- "error",
99
- {
100
- ignoreComments: true
101
- }
102
- ],
103
- "no-whitespace-before-property": [
104
- "error"
105
- ],
106
- "object-curly-newline": [
107
- "error",
108
- {
109
- multiline: true,
110
- consistent: true
111
- }
112
- ],
113
- "object-property-newline": [
114
- "error",
115
- {
116
- allowAllPropertiesOnSameLine: true
117
- }
118
- ],
119
- semi: [
120
- "error",
121
- "always"
122
- ],
123
- "semi-style": [
124
- "error",
125
- "last"
126
- ],
127
- "space-before-blocks": [
128
- "error",
129
- "always"
130
- ],
131
- "space-before-function-paren": [
132
- "error",
133
- "never"
134
- ],
135
- "space-in-parens": [
136
- "error",
137
- "never"
138
- ],
139
- "space-infix-ops": [
140
- "error"
141
- ],
142
- "space-unary-ops": [
143
- "error",
144
- {
145
- words: true,
146
- nonwords: false
147
- }
148
- ],
149
- "switch-colon-spacing": [
150
- "error"
151
- ],
152
- "unicode-bom": [
153
- "error",
154
- "never"
155
- ],
156
- "linebreak-style": [
157
- "error",
158
- "unix"
159
- ],
160
- "no-useless-escape": "off",
161
- quotes: ["error",
162
- "double"
163
- ],
164
- "valid-jsdoc": [
165
- "error",
166
- {
167
- requireReturn: false
168
- }
169
- ],
170
- "require-jsdoc": [
171
- "error",
172
- {
173
- require: {
174
- FunctionDeclaration: true,
175
- MethodDefinition: true,
176
- ClassDeclaration: true,
177
- ArrowFunctionExpression: true,
178
- FunctionExpression: false
179
- }
180
- }
181
- ],
182
- "no-console": [
183
- "error"
184
- ],
185
- "dot-notation": [
186
- "error"
187
- ],
188
- eqeqeq: [
189
- "error",
190
- "always"
191
- ],
192
- "no-alert": [
193
- "error"
194
- ],
195
- "no-caller": [
196
- "error"
197
- ],
198
- "no-eval": [
199
- "error"
200
- ],
201
- "no-extend-native": [
202
- "error"
203
- ],
204
- "no-iterator": [
205
- "error"
206
- ],
207
- "no-loop-func": [
208
- "error"
209
- ],
210
- "no-shadow": [
211
- "error"
212
- ]
213
- },
214
-
215
- };
1
+ module.exports = {
2
+ /**
3
+ * By default, ESLint expects ECMAScript 5 syntax. You can override that setting to enable support
4
+ * for other ECMAScript versions as well as JSX by using parser options. However for IE9 compatibility
5
+ * updating it to ECMAScript 6 or above is currently not permitted. -D
6
+ * */
7
+ env: {
8
+ browser: true,
9
+ amd: true,
10
+ commonjs: true
11
+ },
12
+ extends: "airbnb/legacy",
13
+ rules: {
14
+ "prefer-arrow-callback": "off",
15
+ "prefer-destructuring": "off",
16
+ "comma-dangle": "off",
17
+ "no-restricted-globals": "off",
18
+ "no-restricted-properties": "off",
19
+ //
20
+ "no-unused-vars": "warn",
21
+ "no-var": "off",
22
+ "func-names": "off",
23
+ "consistent-return": "off",
24
+ "prefer-rest-params": "off",
25
+ radix: "off",
26
+ "prefer-spread": "off",
27
+ "no-plusplus": "off",
28
+ camelcase: "off",
29
+ "no-use-before-define": "off",
30
+ "no-lonely-if": "off",
31
+ "no-restricted-syntax": "off",
32
+ "vars-on-top": "off",
33
+ "no-param-reassign": "off",
34
+ "max-len": "off",
35
+ "guard-for-in": "off",
36
+ "no-underscore-dangle": "off",
37
+ "no-bitwise": "off",
38
+ "no-mixed-operators": "off",
39
+ "object-shorthand": "off",
40
+ "block-spacing": [
41
+ "error",
42
+ "always"
43
+ ],
44
+ "brace-style": [
45
+ "error",
46
+ "stroustrup"
47
+ ],
48
+ "comma-spacing": [
49
+ "error",
50
+ {
51
+ before: false,
52
+ after: true
53
+ }
54
+ ],
55
+ "comma-style": [
56
+ "error",
57
+ "last"
58
+ ],
59
+ "computed-property-spacing": [
60
+ "error",
61
+ "never"
62
+ ],
63
+ curly: [
64
+ "error",
65
+ "all"
66
+ ],
67
+ "eol-last": "off",
68
+ "func-call-spacing": [
69
+ "error",
70
+ "never"
71
+ ],
72
+ indent: [
73
+ "error",
74
+ 4
75
+ ],
76
+ "key-spacing": [
77
+ "error",
78
+ {
79
+ beforeColon: false,
80
+ afterColon: true
81
+ }
82
+ ],
83
+ "keyword-spacing": [
84
+ "error",
85
+ {
86
+ before: true,
87
+ after: true
88
+ }
89
+ ],
90
+ "lines-between-class-members": [
91
+ "error",
92
+ "always"
93
+ ],
94
+ "no-multi-spaces": [
95
+ "error"
96
+ ],
97
+ "no-trailing-spaces": [
98
+ "error",
99
+ {
100
+ ignoreComments: true
101
+ }
102
+ ],
103
+ "no-whitespace-before-property": [
104
+ "error"
105
+ ],
106
+ "object-curly-newline": [
107
+ "error",
108
+ {
109
+ multiline: true,
110
+ consistent: true
111
+ }
112
+ ],
113
+ "object-property-newline": [
114
+ "error",
115
+ {
116
+ allowAllPropertiesOnSameLine: true
117
+ }
118
+ ],
119
+ semi: [
120
+ "error",
121
+ "always"
122
+ ],
123
+ "semi-style": [
124
+ "error",
125
+ "last"
126
+ ],
127
+ "space-before-blocks": [
128
+ "error",
129
+ "always"
130
+ ],
131
+ "space-before-function-paren": [
132
+ "error",
133
+ "never"
134
+ ],
135
+ "space-in-parens": [
136
+ "error",
137
+ "never"
138
+ ],
139
+ "space-infix-ops": [
140
+ "error"
141
+ ],
142
+ "space-unary-ops": [
143
+ "error",
144
+ {
145
+ words: true,
146
+ nonwords: false
147
+ }
148
+ ],
149
+ "switch-colon-spacing": [
150
+ "error"
151
+ ],
152
+ "unicode-bom": [
153
+ "error",
154
+ "never"
155
+ ],
156
+ "linebreak-style": [
157
+ "error",
158
+ "unix"
159
+ ],
160
+ "no-useless-escape": "off",
161
+ quotes: ["error",
162
+ "double"
163
+ ],
164
+ "valid-jsdoc": [
165
+ "error",
166
+ {
167
+ requireReturn: false
168
+ }
169
+ ],
170
+ "require-jsdoc": [
171
+ "error",
172
+ {
173
+ require: {
174
+ FunctionDeclaration: true,
175
+ MethodDefinition: true,
176
+ ClassDeclaration: true,
177
+ ArrowFunctionExpression: true,
178
+ FunctionExpression: false
179
+ }
180
+ }
181
+ ],
182
+ "no-console": [
183
+ "error"
184
+ ],
185
+ "dot-notation": [
186
+ "error"
187
+ ],
188
+ eqeqeq: [
189
+ "error",
190
+ "always"
191
+ ],
192
+ "no-alert": [
193
+ "error"
194
+ ],
195
+ "no-caller": [
196
+ "error"
197
+ ],
198
+ "no-eval": [
199
+ "error"
200
+ ],
201
+ "no-extend-native": [
202
+ "error"
203
+ ],
204
+ "no-iterator": [
205
+ "error"
206
+ ],
207
+ "no-loop-func": [
208
+ "error"
209
+ ],
210
+ "no-shadow": [
211
+ "error"
212
+ ]
213
+ },
214
+
215
+ };
@@ -1,20 +1,20 @@
1
- version: 2
2
- updates:
3
- - package-ecosystem: npm
4
- directory: "/"
5
- schedule:
6
- interval: daily
7
- open-pull-requests-limit: 10
8
- versioning-strategy: increase-if-necessary
9
- ignore:
10
- - dependency-name: webpack
11
- versions:
12
- - 5.18.0
13
- - 5.19.0
14
- - 5.20.0
15
- - 5.20.1
16
- - 5.20.2
17
- - 5.21.2
18
- - 5.22.0
19
- - 5.23.0
20
- - 5.24.0
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: npm
4
+ directory: "/"
5
+ schedule:
6
+ interval: daily
7
+ open-pull-requests-limit: 10
8
+ versioning-strategy: increase-if-necessary
9
+ ignore:
10
+ - dependency-name: webpack
11
+ versions:
12
+ - 5.18.0
13
+ - 5.19.0
14
+ - 5.20.0
15
+ - 5.20.1
16
+ - 5.20.2
17
+ - 5.21.2
18
+ - 5.22.0
19
+ - 5.23.0
20
+ - 5.24.0
@@ -1,71 +1,71 @@
1
- # For most projects, this workflow file will not need changing; you simply need
2
- # to commit it to your repository.
3
- #
4
- # You may wish to alter this file to override the set of languages analyzed,
5
- # or to provide custom queries or build logic.
6
- #
7
- # ******** NOTE ********
8
- # We have attempted to detect the languages in your repository. Please check
9
- # the `language` matrix defined below to confirm you have the correct set of
10
- # supported CodeQL languages.
11
- #
12
- name: "CodeQL"
13
-
14
- on:
15
- push:
16
- branches: [ master ]
17
- pull_request:
18
- # The branches below must be a subset of the branches above
19
- branches: [ master ]
20
- schedule:
21
- - cron: '31 12 * * 1'
22
-
23
- jobs:
24
- analyze:
25
- name: Analyze
26
- runs-on: ubuntu-latest
27
- permissions:
28
- actions: read
29
- contents: read
30
- security-events: write
31
-
32
- strategy:
33
- fail-fast: false
34
- matrix:
35
- language: [ 'javascript' ]
36
- # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
37
- # Learn more:
38
- # https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
39
-
40
- steps:
41
- - name: Checkout repository
42
- uses: actions/checkout@v2
43
-
44
- # Initializes the CodeQL tools for scanning.
45
- - name: Initialize CodeQL
46
- uses: github/codeql-action/init@v1
47
- with:
48
- languages: ${{ matrix.language }}
49
- # If you wish to specify custom queries, you can do so here or in a config file.
50
- # By default, queries listed here will override any specified in a config file.
51
- # Prefix the list here with "+" to use these queries and those in the config file.
52
- # queries: ./path/to/local/query, your-org/your-repo/queries@main
53
-
54
- # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
55
- # If this step fails, then you should remove it and run the build manually (see below)
56
- - name: Autobuild
57
- uses: github/codeql-action/autobuild@v1
58
-
59
- # ℹ️ Command-line programs to run using the OS shell.
60
- # 📚 https://git.io/JvXDl
61
-
62
- # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
63
- # and modify them (or add more) to build your code if your project
64
- # uses a compiled language
65
-
66
- #- run: |
67
- # make bootstrap
68
- # make release
69
-
70
- - name: Perform CodeQL Analysis
71
- uses: github/codeql-action/analyze@v1
1
+ # For most projects, this workflow file will not need changing; you simply need
2
+ # to commit it to your repository.
3
+ #
4
+ # You may wish to alter this file to override the set of languages analyzed,
5
+ # or to provide custom queries or build logic.
6
+ #
7
+ # ******** NOTE ********
8
+ # We have attempted to detect the languages in your repository. Please check
9
+ # the `language` matrix defined below to confirm you have the correct set of
10
+ # supported CodeQL languages.
11
+ #
12
+ name: "CodeQL"
13
+
14
+ on:
15
+ push:
16
+ branches: [ master ]
17
+ pull_request:
18
+ # The branches below must be a subset of the branches above
19
+ branches: [ master ]
20
+ schedule:
21
+ - cron: '31 12 * * 1'
22
+
23
+ jobs:
24
+ analyze:
25
+ name: Analyze
26
+ runs-on: ubuntu-latest
27
+ permissions:
28
+ actions: read
29
+ contents: read
30
+ security-events: write
31
+
32
+ strategy:
33
+ fail-fast: false
34
+ matrix:
35
+ language: [ 'javascript' ]
36
+ # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
37
+ # Learn more:
38
+ # https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
39
+
40
+ steps:
41
+ - name: Checkout repository
42
+ uses: actions/checkout@v2
43
+
44
+ # Initializes the CodeQL tools for scanning.
45
+ - name: Initialize CodeQL
46
+ uses: github/codeql-action/init@v1
47
+ with:
48
+ languages: ${{ matrix.language }}
49
+ # If you wish to specify custom queries, you can do so here or in a config file.
50
+ # By default, queries listed here will override any specified in a config file.
51
+ # Prefix the list here with "+" to use these queries and those in the config file.
52
+ # queries: ./path/to/local/query, your-org/your-repo/queries@main
53
+
54
+ # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
55
+ # If this step fails, then you should remove it and run the build manually (see below)
56
+ - name: Autobuild
57
+ uses: github/codeql-action/autobuild@v1
58
+
59
+ # ℹ️ Command-line programs to run using the OS shell.
60
+ # 📚 https://git.io/JvXDl
61
+
62
+ # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
63
+ # and modify them (or add more) to build your code if your project
64
+ # uses a compiled language
65
+
66
+ #- run: |
67
+ # make bootstrap
68
+ # make release
69
+
70
+ - name: Perform CodeQL Analysis
71
+ uses: github/codeql-action/analyze@v1
@@ -0,0 +1,24 @@
1
+ name: Documentation
2
+
3
+ on:
4
+ push:
5
+ branches: [ master ]
6
+ pull_request:
7
+ branches: [ master ]
8
+
9
+ jobs:
10
+ docs:
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - uses: actions/checkout@v2
14
+ - name: Use Node.js ${{ matrix.node-version }}
15
+ uses: actions/setup-node@v2
16
+ with:
17
+ node-version: 14.x
18
+ - run: npm install
19
+ - name: Deploy documentation
20
+ shell: bash
21
+ env:
22
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23
+ run: bash generateDocs.sh
24
+