nerdexam
Adobe

AD0-E409 · Question #124

A client would like to use at.js 2.x to integrate third-party weather data from a service that provides the temperature of the site visitor's location based on IP. This will allow the client to…

The correct answer is B. Content hiding is enabled until the Data Provider resolves using the callback function passed to. Option B is correct because Data Providers integrate with at.js's body-hiding (flicker-prevention) mechanism: at.js keeps the page body hidden until every registered Data Provider fires its callback, guaranteeing that third-party data (like the weather temperature) is fully…

Implementation and Integration

Question

A client would like to use at.js 2.x to integrate third-party weather data from a service that provides the temperature of the site visitor's location based on IP. This will allow the client to promote products to visitors based on their local weather. The third-party weather request needs to resolve with the temperature before the global Target request (mbox) happens. A Data Provider will be used to gather this data in lieu of targetPageParams(). Why should Data Providers be used instead of targetPageParams()?

Options

  • AThe window.targetPageParams() function disables body hiding when used.
  • BContent hiding is enabled until the Data Provider resolves using the callback function passed to
  • CThe targetPageParams() function is not supported in at.js 2.x.
  • DData Providers offer a built in XHR function to make a third party request to the weather service.

How the community answered

(22 responses)
  • A
    14% (3)
  • B
    82% (18)
  • D
    5% (1)

Explanation

Option B is correct because Data Providers integrate with at.js's body-hiding (flicker-prevention) mechanism: at.js keeps the page body hidden until every registered Data Provider fires its callback, guaranteeing that third-party data (like the weather temperature) is fully resolved before the global mbox request fires. targetPageParams() is synchronous - it cannot await an asynchronous XHR response, so the mbox would fire before the weather data arrives, making it useless for this use case.

Why the distractors are wrong:

  • A is false - targetPageParams() does not disable body hiding; it has no effect on that mechanism.
  • C is false - targetPageParams() is still supported in at.js 2.x; the problem is its synchronous nature, not availability.
  • D is false - Data Providers provide no built-in XHR utility; you supply your own fetch/XHR logic inside the provider function.

Memory tip: Think "Data Providers = Delay & Provide." They delay page reveal (body hiding stays on) until the callback resolves, and provide that data to Target - exactly what async third-party lookups require.

Topics

#at.js 2.x#Data Providers#targetPageParams#content hiding

Community Discussion

No community discussion yet for this question.

Full AD0-E409 Practice