Expand my Community achievements bar.

SOLVED

Initiate Target on a Next.js reload (similar to an AJAX call)

Avatar

Level 2

We have a page that uses ReactJS, Chakra UI and Next.js and we can do a form base client-side test ok, but on this specific page, there is a CTA out to make some changes and when the customer saves to return back, the page doesn't actually reload, it's very similar to an AJAX call, but I think it's using Next.js.  The behaviour is as expected, but there is NOTHING coming through in the Network tab in dev tools when you see the activity on this call which indicates launch is not being run and initiating Target.   

 

I can't seem to make head nor tails on how to fix with this:

https://experienceleague.adobe.com/docs/target-dev/developer/client-side/at-js-implementation/functi...

 

If indeed this is the solution?

 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor and Adobe Champion

Dear @andywoodrow ,

If there is no event dispatching from the page for the Launch to trigger the rule, you should use Direct Call.

When the customer saves and returns back to the page, try to dispatch a Direct Call from the page and use the same in Launch to trigger the Target.

Thank You, Pratheep Arun Raj B (Arun) | NextRow DigitalTerryn Winter Analytics

 

View solution in original post

1 Reply

Avatar

Correct answer by
Community Advisor and Adobe Champion

Dear @andywoodrow ,

If there is no event dispatching from the page for the Launch to trigger the rule, you should use Direct Call.

When the customer saves and returns back to the page, try to dispatch a Direct Call from the page and use the same in Launch to trigger the Target.

Thank You, Pratheep Arun Raj B (Arun) | NextRow DigitalTerryn Winter Analytics