How can i store after user click the buttons using tinydb



If any of these button is clicked, save it tinydb with value as clicked button text or use your custom text, as weekly/monthly/yearly then whenever screen init call this tinydb first

block exmple


if helpful mark as solution

you can optimize your block by using a dictionary, keys being components and values being text “weekly”, “monthly”… and then just use get value using a key component from dictionary, anyway here’s the blocks

can @yashsrv convert my block to your block exmaple