i'm creating a desktop application that make use of Python as the backend application. In a simple scenario i would like to display random numbers continuously (For e.g. in console window)
import random
from time import sleep
while True:
print "Random number: " + str(random.randint(1, 10))
sleep(0.5)
I came upon this article https://www.fyears.org/2017/02/electron-as-gui-of-python-apps-updated.html which make use of the input to calculate the numbers dynamically.
May i ask how do i implement the script above without using any button? I'm stuck with what to put in the renderer.js to render the above logic.