How do I add input radio in my app theme settings

How do I add input radio in my app theme settings

webmaster5
Shopify Partner
5 0 0

I want to be able to insert radio button inputs for my app inside the theme settings in the right column.

 

The radio button options will need to come from my API, and when the user selects one of the options, I need to save it and retrieve the selected option every time the user opens the theme settings app.

 

How can I insert radio buttons in the right column of my app settings? Please see the attached screenshot showing where I want to display the radio buttons with the options so that the user can select one.

Thank you for your help.

 

Screenshot at Sep 07 18-54-40.png

Replies 3 (3)

Shine18pk
Shopify Partner
30 7 14

Hey @webmaster5 
Have you tried using this: https://shopify.dev/docs/themes/architecture/settings/input-settings#radio 

- Need a Shopify developer? Chat on WhatsApp
- For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
- Your Coffee Tip , my code - a perfect blend! ❤️
DownUnderDev
Shopify Partner
3 0 0

Thanks @Shine18pk 

 

How would you render those options from dynamic API values from a GET request?

 

I have got a similar scenario but can't figure out how to create the options based on an API response.

webmaster5
Shopify Partner
5 0 0

Thanks @Shine18pk 

I had a look at it, but I am unsure how to implement it in a dynamic way, how to call the API, and how to save the values. Do you happen to know how to do so? My main struggle is how to perform API calls for those configs.