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
undefined properties of data element for web-vitals #10
Comments
@PH1NO The Data Elements have to be used in a Rule that has one of the Events from my Extension. For example, if you have a Rule that is triggered with the "Cumulative Layout Shift (CLS)" Event, then in that Rule's Conditions and/or Actions, you can use the Data Elements from my Extension. Then you'll be able to get the expected values. So my question is: in your Rule(s) where you are using these Web Vitals Data Elements, which Event(s) are you triggering with? |
Hi @yuhui , thank you for your reply. So I missed the step of adding those events to the rule, I've done a separate rule on it's own to fire when any of those Web Vitals events occur and I've tried it on a page load rule. When I try to send those data elements through the actions (via set variables) or in custom code, I don't see any results. Here is my set up for the rule Here is the data element set up (just selected my Attribution data element for this example) Here is the error I get for the Attribution one: When i tried console logging it, that threw an error as well stating that the web-vitals cannot grab any data due to it being undefined. Unless I'm implementing incorrectly? But I tried going through the step by step process I've seen with your extension. Thanks so much for your assistance |
Hi @PH1NO, can you provide the URL of the web page where you’re using my Web Vitals extension? Or if you’re not able to do that, can you provide the URL of your assets.adobedtm.com Launch environment script?
You can email me at yuhui (at) yuhui (dot) sg.
Message ID: ***@***.***>
|
Will do. Thank you! |
Thank you @yuhui for your assistance! |
I've installed the Web Vitals extension to Adobe Experience Platform via the Extensions. I've created the data elements that are preset after installing Web Vitals. When I try to use the console log for metrics, I receive "undefined" for all and when I try to grab the data element via _satellite, i get the following:
_satellite.getVar('Web-Vitals_Delta', event)
VM9:106 🚀 Failed to execute data element module web-vitals-js/src/lib/dataElements/metricDelta.js for data element Web-Vitals_Delta. Cannot read properties of undefined (reading 'webvitals')
TypeError: Cannot read properties of undefined (reading 'webvitals')
Browsers used:
The text was updated successfully, but these errors were encountered: