'How to handle the routing from the backend as flikart does

I am a newbie and i wanted to actually build a ecommerce app.

And i want to actually build an app in which the corousel is managed by the backend But i wonder how to the flipkart, amazon does that .

Like enter image description here

Here the corousel images is all managed by the backend . How to actually set the navigation of that particular image on the fly ,

Because we would not be knowing the image at all in the first place..

In android/ios there are many images, one is of discount , one is of specific product, How to actually control where the app should be navigated when the image is pressed well from the backend.

If it is the specific product => it should get navigated to the specific product
If it is about discount => it should go to discount page where there is all products listings.

I am new to this.

So any help would be appreciated.

How to achieve this in flutter or any other platform for that matter. To dynamically set the destination of the image which is controlled by backend



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source