- TLC Home Home
- Discussions Discussions
- Documentation Documentation
- Knowledge Base Knowledge Base
- Education Education
- Blog Blog
- Support Desk Support Desk
06-06-2019 07:28 AM
Hello,
In the Tealium for JavaScript / Web, the `utag.view` method accepts an optional third parameter `uid_array` which is an array of tag IDs that you can limit the tracking call to: https://docs.tealium.com/platforms/javascript/page-tracking/#utag-view
I'm using Tealium for React Native, which uses a `trackView` method: https://docs.tealium.com/platforms/react-native/functions/#trackview
Is there a way to limit a React Native `trackView` call to only certain tag IDs, similar to how it's done on JavaScript / Web? The workaround I have planned is to pass in key/value pairs in the data object from `trackView`, and then on the Tealium dashboard, set up load rules for our multiple tags to either add or not add based on that. But it would be easier to be able to just pass in tag IDs from the React Native call (to specify which tags to load) without adding multiple load rules and maintaining those on the Tealium side.
Thanks!
09-13-2019 02:52 AM
HI,
Actually personally I find IDs not very robusts as any one could remove and add a tag changing the IDs so your code would break. It's also hard to manage in terms of libraries: the tag would have a different ID in every profile. In this instance I would recommend using the trackEvent() method and create your own event for instance ("scroll", "ads_impression", etc..)
You can then go in the template of the tag and add that event at the top
u.ev = {"view" : 1, "link": 1,"scroll":1};
So this means you can whitelist some tags and only the tags with that event will fire when you trigger your call in React.
Hopes this helps
Copyright All Rights Reserved © 2008-2023