-
Notifications
You must be signed in to change notification settings - Fork 55
feat: Include consent query parameters for cookie sync #966
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: development
Are you sure you want to change the base?
Conversation
b28c45d to
29f34b0
Compare
2c977b9 to
9246789
Compare
29f34b0 to
78a0cb2
Compare
9246789 to
85f1887
Compare
src/cookieSyncManager.ts
Outdated
| import Constants from './constants'; | ||
| import { MParticleWebSDK } from './sdkRuntimeModels'; | ||
| import { MPID } from '@mparticle/web-sdk'; | ||
| import { Logger, MPID } from '@mparticle/web-sdk'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| import { Logger, MPID } from '@mparticle/web-sdk'; | |
| import { MPID } from '@mparticle/web-sdk'; |
src/cookieSyncManager.ts
Outdated
|
|
||
| declare global { | ||
| interface Window { | ||
| __tcfapi: any; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we come up with a simple definition?
test/jest/cookieSyncManager.spec.ts
Outdated
| } as unknown) as MParticleWebSDK; | ||
|
|
||
| beforeEach(() => { | ||
| cookieSyncManager = new CookieSyncManager(mockMpInstance); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this actually being used after the last reactor we discussed?
test/jest/cookieSyncManager.spec.ts
Outdated
| const errorLoggerSpy = jest.fn(); | ||
| const mockUrl = 'https://example.com/cookie-sync'; | ||
|
|
||
| let cookieSyncManager: any; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we still need this?
|
78a0cb2 to
c9a2723
Compare



Instructions
developmentSummary
window.__tcfapito return TCF strings which contains what a user has/has not consented. This gets appended to the end of a cookie sync.tcDataobject, and we only need the keysgdprAppliesandtcStringTesting Plan
Added unit tests
Reference Issue (For mParticle employees only. Ignore if you are an outside contributor)